\n"; $data = "

Response exceeds size limit of 500,000 bytes. Use a smaller value of count.

"; } fclose($fd); # Write query result to a temporary file $tmpfile = tempnam("tmp", ''); $tmpfile = "$tmpfile.xml"; $fd = fopen($tmpfile, 'w'); fputs($fd, $xmlDecl); fputs($fd, "\n"); fputs($fd, "\n"); fputs($fd, $data); fclose($fd); chmod($tmpfile, 0644); # Use the default stylesheet if no argument was given if (!$xsl) { $xsl = "http://www.language-archives.org/tools/viser/basic_service.xsl"; } # Set up the XSLT processor $java = "/pkg/j/j2sdk1.4.0/bin/java"; $xalan = "/mnt/unagi/ldc/wwwhome/jakarta-tomcat-3.2.3-sb/lib/xalan.jar"; $xerces = "/pkg/x/xerces-2_0_1/xercesImpl.jar"; $xslt = "$java -classpath $xalan:$xerces org.apache.xalan.xslt.Process -xsl $xsl"; # Transform output $command = "$xslt -IN $tmpfile -PARAM title \"$title\""; exec($command, $result); # Return the HTML page header("Content-Type: text/html"); print join("\n", $result); ?>