You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Sue Evans <se...@blackboard.com> on 2000/11/21 19:49:20 UTC

Cocoon and Xlink don't work

My problem is that I can't get cocoon to display an xlink.  It only displays
the text of the link name, but doesn't make it a hotlink.  I saw a few posts
to this listserv but none of the information seems to solve my problem.

I am using Cocoon 1.8.  I am not getting any error messages - I just can't
get any links to appear as links.  If you know of any configuration that I
need to do on the Cocoon side, or if you can point me in the right
direction, I would really appreciate it.  I give an example below of my
simple example.  Thanks for any help you can give.

- Sue Evans

 

Here is the simple example I am trying to get to work including the xml, the
xsl and the result:

#########################################################################
xml file:

<?xml version="1.0"?>
<?xml-stylesheet href="simple.xsl" type="text/xsl"?>
<?cocoon-process type="xslt"?>

<!DOCTYPE page [
<!ELEMENT page (mylink+)>
<!ELEMENT mylink (#PCDATA)>
<!ATTLIST mylink
    xml:link      CDATA               #FIXED "simple"
    href          CDATA               #REQUIRED
    content-role  CDATA               #IMPLIED
>
]>

<page>
<mylink xmlns:xlink="http://www.w3.org/1999/xlink" xml:link="simple"
title="Citation"
   href="http://www.xyz.com/xml/foo.xml" show="new"
   content-role="Reference">Simple Link</mylink>
</page>

############################################################################
#########
xsl:

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

   <xsl:template match="/">

   <html>
   <body bgcolor="#ffffff">
   Here are the links...
   <xsl:value-of select="page"/>
    </body>
   </html>

</xsl:template>
</xsl:stylesheet>


############################################################################
###############

result:

<html><body bgcolor="#ffffff"> Here are the links...
   
Simple Link
</body></html>