ItemapplyStylesheet Method |
Performs XSL transformation of the item's DOM and returns the result of the transformation.
IMPORTANT: Be very carefull when using slylesheets from untrusted urls, there's a possibility to use scripts in the stylesheets with the code that can cause damage.
Make sure that the stylesheet doesn't contain intrader's script code before using.
Namespace:
Aras.IOM
Assembly:
IOM (in IOM.dll) Version: 14.0.9.36244
Syntaxpublic string applyStylesheet(
string xslStylesheet,
string type
)
Public Function applyStylesheet (
xslStylesheet As String,
type As String
) As String
public String applyStylesheet(
String xslStylesheet,
String type
)
public function applyStylesheet(
xslStylesheet : String,
type : String
) : String
Parameters
- xslStylesheet
- Type: SystemString
If type='text' then it's XML text for the stylesheet; if type='url' then it's URL
of a stylesheet file.
- type
- Type: SystemString
The type argument is either 'text' or a 'url' (case insensitive).
Return Value
Type:
String
String that represents XML of the item's DOM after XSL transformation.
ExceptionsException | Condition |
---|
XmlException | Failed to load the xsl. |
XsltCompileException | Specified xsl does not conform to a valid stylesheet. |
Remarks-
If type='url' the xslStylesheet argument is interpreted as file URL. It means that user
can pass to the method URLs like: "http://localhost/mystylesheets/stylesheet1.xslt" or "file:///c:/tmp/stylesheet2.xslt";
or absolute or relative path to the file, e.g. "c:/tmp/stylesheet2.xslt" or "../../stylesheet3.xslt".
-
The item itself is not modified by the method.
See Also