php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #20518 xslt_set_base has no effect
Submitted: 2002-11-20 08:37 UTC Modified: 2002-11-21 17:29 UTC
From: erwan at barzhoneg dot com Assigned: msopacua (profile)
Status: Closed Package: XSLT related
PHP Version: 4.3.0RC1 OS: win2000 / IIS 5
Private report: No CVE-ID: None
 [2002-11-20 08:37 UTC] erwan at barzhoneg dot com
when I use the following code in an include, the xslt base directory defaults the directory of the include (probably has something to do with bug #20514 and the current directory in includes).

The big problem is that  The xslt_base function doesn't change the base directory for xslt processing. As a result, imports and dtd references don't work. The solution obviously is to place the xslt functions include in the same directory as the xsl, xml and dtd files. Is this a bug ?

$args = array ( '/_xml' => $str_xml ,
	'/_xsl' => $str_xsl);
$xp = xslt_create();
xslt_set_base( $xp,'file:///D:/www/xadmin/');
$out = xslt_process($xp, 'arg:/_xml', 'arg:/_xsl', NULL, $args, $params);
xslt_free($xp);

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-11-20 13:24 UTC] msopacua@php.net
It's actually related to #20177.

You are right that once xslt_set_base is called, we shouldn't override this.

Assigned.
 [2002-11-21 17:29 UTC] msopacua@php.net
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 20:01:45 2024 UTC