Click to See Complete Forum and Search --> : xml example


gert cuykens
10-30-2006, 06:17 PM
How can you make this xml doc work in firefox2 ?<?xml version="1.0" encoding="ISO-8859-1"?>

<header>
XML
</header>

<paragraph>
blablablablabla
</paragraph>

<xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">

<xsl:template match="header">
<fo:block
font-size="14pt" font-family="verdana" color="red"
space-before="5mm" space-after="5mm">
<xsl:apply-templates/>
</fo:block>
</xsl:template>

<xsl:template match="paragraph">
<fo:block
text-indent="5mm"
font-family="verdana" font-size="12pt"
space-before="5mm" space-after="5mm">
<xsl:apply-templates/>
</fo:block>
</xsl:template>

</fo:root>
</xsl:transform> I am guessing by using xhtml but maybe somebody know some other things i dont know what is usaly the case around here :D

gert cuykens
10-30-2006, 06:37 PM
Or could anybody make this work in firefox2 :D <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:py="http://purl.org/kid/ns#"
xmlns:fo="http://www.w3.org/1999/XSL/Format"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xml:lang="en">
<head>
<xsl:transform>
<fo:root>
<xsl:template match="/html/body/p">
<fo:block
text-indent="5mm"
font-family="verdana"
font-size="18px"
space-before="5mm"
space-after="5mm">
<xsl:apply-templates/>
</fo:block>
</xsl:template>
</fo:root>
</xsl:transform>
</head>
<body>
<p>
blablablablabla
</p>
</body>
</html>