cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roderick A. Carder-Russell" <r_car...@mail.plymouth.edu>
Subject Connecting to MySQL...
Date Thu, 29 Jun 2000 18:29:25 GMT

I'm attempting to connect to a MySQL database and extract information to
be placed into my XML document.  I've put all of what I believe are the
appropriate tags into the documents, including the XSL to reference and
print out my data to a browser.  It does not seem to want to cooperate
though.  What I end up seeing is a blank browser window.  I don't even get
any error message.  I've included the the trimmed down markup below.  I'd
be greatful if anyone could spot problems or give advice.

------THE XML DOCUMENT------

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

<test>
	<connection name="dbconnection">
		<driver>org.gjt.mm.mysql.Driver</driver>
		<dburl>jdbc:mysql://www.myserver.com/mydb</dburl>
		<username>myusername</username>
		<password>mypassword</password>
	</connection>

	<query connection="dbconnection">
		SELECT myfield FROM mytable ORDER BY myfield; 	
	</query>     	
</test>


-------THE XSL DOCUMENT------

<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<xsl:processing-instruction name="cocoon-format">type="text/html"</xsl:processing-instruction>

<xsl:for-each select="test">
	<xsl:value-of select="myfield"/>
</xsl:for-each>

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


--------------
Roderick A. Carder-Russell
rodc@shore.net
--------------


Mime
View raw message