Topic: error in xsl file can somebody help? (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=25185" title="Pages that link to Topic: error in xsl file can somebody help? (Page 1 of 1)" rel="nofollow" >Topic: error in xsl file can somebody help? <span class="small">(Page 1 of 1)</span>\

 
conny
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Mar 2005

posted posted 03-05-2005 06:08

been doing on a ASP, XMl ,XSL project in my studies.. I got little knowledge on XSL so all my things are all read from book but i have encounter this error when i try to run this xsl file.

this is the error

The character '<' cannot be used in an attribute value. Error processing resource 'http://localhost/imported.xsl'. Line 7,...

<html>
--^

this is my xsl file.


<?xml version="1.0"?>
<xsl:stylesheet version ="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:output method="html"/>

<xsl:template match="/'>
<html>
<body>
<xsl:for-each select="//quiz|//concept|//topic|//level|//question">
<p>
<xsl:apply-templates select="."/>
</p>
</xsl:for-each>
</body>
<html>
</xsl:template>

<xsl:template match="topic">
<xsl:text>True or False: </xsl:text><xsl:value-of select=".">
</xsl:template>

<xsl:template match="level">
<b><xsl:value-of select="name()"/>:</b>
<br/>
<xsl:value-of select="."/>:</b>
</xsl:template>

<xsl:template match="question">
<b><xsl:value-of select="name()"/>:</b>
<br/>
<xsl:value-of select="."/>:</b>
</xsl:template>
</xsl:stylesheet>

Conny (confused)

(Edited by bitdamaged on 03-05-2005 07:12)

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 03-05-2005 07:13

(... just turned off smiley)

You're not closing the html tag

<html>
<body>
<xsl:for-each select="//quiz|//concept|//topic|//level|//question">
<p>
<xsl:apply-templates select="."/>
</p>
</xsl:for-each>
</body>
<html>



.:[ Never resist a perfect moment ]:.

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 03-05-2005 07:15

oh and you're mismatching the quotes

<xsl:template match="/'>



.:[ Never resist a perfect moment ]:.

conny
Obsessive-Compulsive (I) Inmate

From:
Insane since: Mar 2005

posted posted 03-05-2005 07:56

huh? what do you mean by mismatching?? sorry i really bad in this.

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 03-05-2005 08:00

you've got one single and one double quote.



.:[ Never resist a perfect moment ]:.

conny
Obsessive-Compulsive (I) Inmate

From:
Insane since: Mar 2005

posted posted 03-05-2005 08:10

OH!! haha THANKS!



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu