Jump to content

Search the Community

Showing results for tags 'XML XSL'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • HTML/XHTML
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • XSLT/XSL-FO
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Languages

Found 2 results

  1. I would like to have my stylesheet use an XML output and if possible use it with a table. I seem to only get this to work with a HTML output not a XML output. I am fairly new at XML so any examples of how to do this or suggestions would be greatly appreciated. Here is my XML code <?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet href="Lesson_8_obj_1.xsl" type="text/xsl"?><!DOCTYPE Employees><Employees xmlns:xsi="http://www.w3.org/20...Schema-instance"xsi:noNamespaceSchemaLocation="xsd.xsd">> <Employee> <First>John</First> <Last>Smith</Last> <Phone Type="Home">1-800-123-4567</Phone> <Birthday>1960-05-25</Birthday> <HourlyRate>35.85</HourlyRate></Employee> <Employee> <First>Jane</First> <Last>Jones</Last> <Phone Type="Cell">1-800-999-9999</Phone> <Birthday>1980-11-01</Birthday> <HourlyRate>58.17</HourlyRate></Employee></Employees> Here is my XSL code. <?xml version="1.0" ?><xsl:stylesheet version="1.0"xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:output method="xml" indent="yes"/> <xsl:template match="/"><table> <tr> <th>First</th> <th>Last</th> <th>Phone</th> <th>Birthday</th> <th>HourlyRate</th> </tr><xsl:for-each select="Employees/Employee"> <tr> <td><xsl:value-of select="First"/></td> <td><xsl:value-of select="Last"/></td> <td><xsl:value-of select="Phone"/></td> <td><xsl:value-of select="Birthday"/></td> <td><xsl:value-of select="HourlyRate"/></td></tr></xsl:for-each> </table> </xsl:template></xsl:stylesheet>
  2. I would like to have my stylesheet use an XML output and if possible use it with a table. I seem to only get this to work with a HTML output not a XML output. I am fairly new at XML so any examples of how to do this or suggestions would be greatly appreciated. Here is my XML code <?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet href="Lesson_8_obj_1.xsl" type="text/xsl"?><!DOCTYPE Employees><Employees xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:noNamespaceSchemaLocation="xsd.xsd">> <Employee> <First>John</First> <Last>Smith</Last> <Phone Type="Home">1-800-123-4567</Phone> <Birthday>1960-05-25</Birthday> <HourlyRate>35.85</HourlyRate></Employee> <Employee> <First>Jane</First> <Last>Jones</Last> <Phone Type="Cell">1-800-999-9999</Phone> <Birthday>1980-11-01</Birthday> <HourlyRate>58.17</HourlyRate></Employee></Employees> Here is my XSL code. <?xml version="1.0" ?><xsl:stylesheet version="1.0"xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:output method="xml" indent="yes"/> <xsl:template match="/"><table> <tr> <th>First</th> <th>Last</th> <th>Phone</th> <th>Birthday</th> <th>HourlyRate</th> </tr><xsl:for-each select="Employees/Employee"> <tr> <td><xsl:value-of select="First"/></td> <td><xsl:value-of select="Last"/></td> <td><xsl:value-of select="Phone"/></td> <td><xsl:value-of select="Birthday"/></td> <td><xsl:value-of select="HourlyRate"/></td></tr></xsl:for-each> </table> </xsl:template></xsl:stylesheet>
×
×
  • Create New...