|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Which is more efficient?
Which of these is the most efficient way of rendering html? It's obvious which one is easier to code, but which one would actually parse more quickly? In the abbreviated examples below, the difference, of course would be negligible...but consider a page of a few thousand lines of rendered HTML. SCENARIO #1: ---------------------- <?xml version = "1.0" encoding = "UTF-8"?> <xsl:stylesheet version = "1.0" xmlns:xsl = "http://www.w3.org/1999/XSL/Transform"> <xmlRoot> <table border="1" cellspacing="1"> <tr> <td>abc</td> </tr> </table> </xmlRoot> </xsl:stylesheet> SCENARIO #2: ---------------------- <?xml version = "1.0" encoding = "UTF-8"?> <xsl:stylesheet version = "1.0" xmlns:xsl = "http://www.w3.org/1999/XSL/Transform"> <xmlRoot> <xsl:element name="table"> <xsl:attribute name="border"> <xsl:text>1</xsl:text> </xsl:attribute> <xsl:attribute name="cellspacing"> <xsl:text>1</xsl:text> </xsl:attribute> <xsl:element name="tr"> <xsl:element name="td"> <xsl:text>abc</xsl:text> </xsl:element> </xsl:element> </xsl:element> </xmlRoot> </xsl:stylesheet> ------------------------------------------------------------------------------ This e-mail transmission may contain information that is proprietary, privileged and/or confidential and is intended exclusively for the person(s) to whom it is addressed. Any use, copying, retention or disclosure by any person other than the intended recipient or the intended recipient's designees is strictly prohibited. If you are not the intended recipient or their designee, please notify the sender immediately by return e-mail and delete all copies. ============================================================================== XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








