note 48659 added to function.xsl-xsltprocessor-set-parameter

From: Date: Tue, 04 Jan 2005 01:42:52 +0000
Subject: note 48659 added to function.xsl-xsltprocessor-set-parameter
Groups: php.notes 
Request: Send a blank email to php-notes+get-82661@lists.php.net to get a copy of this message
Little example... transform.php: <?php $name="mr. Anderson"; $xml = new DomDocument; $xml->load('example.xml'); $xsl = new DomDocument; $xsl->load('example.xsl'); $proc = new xsltprocessor; $proc->setParameter('', 'name', $name); $proc->importStyleSheet($xsl); echo $proc->transformToXML($xml); ?> example.xsl: <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="html" encoding="iso-8869-1" indent="no"/> <xsl:template match="/"> <h3>Hello, <xsl:value-of select="$name"/></h3> </xsl:template> </xsl:stylesheet> example.xml: <?xml version="1.0" encoding="iso-8859-1" ?> <names> </names> ---- Manual Page -- http://www.php.net/manual/en/function.xsl-xsltprocessor-set-parameter.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+48659 Delete -- http://master.php.net/manage/user-notes.php?action=delete+48659&report=yes Reason: bad code -- http://master.php.net/manage/user-notes.php?action=delete+48659&report=yes&reason=bad+code Reason: spam -- http://master.php.net/manage/user-notes.php?action=delete+48659&report=yes&reason=spam Reason: useless example -- http://master.php.net/manage/user-notes.php?action=delete+48659&report=yes&reason=useless+example Reason: contains commercial links -- http://master.php.net/manage/user-notes.php?action=delete+48659&report=yes&reason=contains+commercial+links Reason: useless note -- http://master.php.net/manage/user-notes.php?action=delete+48659&report=yes&reason=useless+note Reject -- http://master.php.net/manage/user-notes.php?action=reject+48659&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#82661) next »