Transforming XML using XSLT to an HTML pageXML files hold the data that is to be displayed in the html file. An XSL file holds the information on how to transform that xml data and display it. The style information and the format in which the data has to be displayed are available in the XSL file. It is possible to include this style sheet file in the xml file itself and open the xml file to display the data in the style you want. For example if you include the code, <?xml-stylesheet type="text/xsl" href="ur_xsl_file.xslt"?> The result of including the above code will transform the xml file according to the style and formatting information that is found in the 'ur_xsl_file.xslt'. ASP.Net and other technologies provide you ways to do this in the code. In ASP.Net the classes for this are available in the namespace System.Xml and System.Xml.Xsl. You can use an xml server control in your aspx page and set the document source and the transform source for the xml control through code in the Page_Load event of the aspx file.
|
|
||
|
|||
“Amazon and the Amazon logo are trademarks of Amazon.com, Inc. or its affiliates.”
Copyright - © 2004 - 2019 - All Rights Reserved.