cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ben Pope" <nos...@hotmail.com>
Subject RE: html entity problem
Date Sat, 31 Jul 2004 19:40:00 GMT
Try being a bit more specific, I still don't know what it is that you intend
to do.

I have no idea why you created a DTD for the entity.

If you want to output html by writing it inside your XSLT as you would in an
editor, without having to worry about the parser parsing it, or the
serialiser playing with it, do this:

<xsl:text disable-output-escaping="yes"><![CDATA[&nbsp; <!-- and other html
stuff -->]]></xsl:text>

The CDATA section makes the parser leave it alone, and the DOE makes the
serialiser leave it alone.

Which should have been described fully in the references I gave.

Enjoy.

Ben




________________________________

From: beyaNet [mailto:andrew@beyanet.com] 
Sent: 31 July 2004 10:36
To: users@cocoon.apache.org
Subject: Re: html entity problem


Hi Ben,
thanks for your reply. I have included the following code into my xsl
template which seems to solve the problem, but introduces another one:

<?xml version="1.0"?>

<!DOCTYPE xsl:stylesheet [
<!ENTITY nbsp "&#160;">
]> 

When the xhtml page is generated it renders the following character to the
screen:

 

How do i resolve that?

thanks

Andrew
On 31 Jul 2004, at 10:14, Ben Pope wrote:



	Hi,
	
	Handle them how?
	
	You may find these two pages useful, that basically deal with the
input and
	output:
	http://www.dpawson.co.uk/xsl/sect2/cdata.html
	
	http://www.dpawson.co.uk/xsl/sect2/N2215.html
	
	Pay particular attention to:
	http://www.dpawson.co.uk/xsl/sect2/N2215.html#d3358e217
	
	To determine when each is useful (Might as well read this first, if
it
	doesn't make sense, look above)
	
	Ben
	
	
	
	-----Original Message-----
	From: beyaNet [mailto:andrew@beyanet.com] 
	Sent: 31 July 2004 09:59
	To: users@cocoon.apache.org
	Subject: html entity problem
	
	Hi,
	what code do I need to place inside my xsl template to handle html
entities
	such as &nbsp; ?
	
	thanks
	
	Andrew
	
	
	
---------------------------------------------------------------------
	To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
	For additional commands, e-mail: users-help@cocoon.apache.org
	
	
	
---------------------------------------------------------------------
	To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
	For additional commands, e-mail: users-help@cocoon.apache.org
	
	


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message