#29798 [Opn->Csd]: SimpleXML xpath function can't hable SCORM manifest xml files

From: Date: Mon, 23 Aug 2004 13:37:02 +0000
Subject: #29798 [Opn->Csd]: SimpleXML xpath function can't hable SCORM manifest xml files
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-65091@lists.php.net to get a copy of this message
ID: 29798 Updated by: chregu@php.net Reported By: timo at hhesse dot de -Status: Open +Status: Closed Bug Type: SimpleXML related Operating System: Windows 2000 PHP Version: 5.0.1 New Comment: This bug has been fixed in CVS. 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/. Thank you for the report, and for helping us make PHP better. you have a default namespace there, therefore normal xpath queries won't work. you have to use registerXPathNamespace, which only will be available in PHP 5.1 see http://blog.bitflux.ch/p1746.html for more information. Previous Comments: ------------------------------------------------------------------------ [2004-08-23 15:26:46] timo at hhesse dot de Description: ------------ I made several tests, but it seems like simpleXML->xpath() can't get along with a well formed SCORM imsmanifest.xml file. I can't access the document by xpath queries. result is always array(0). after removing all the parameters of the root <manifest> element, it works. Sample SCORM compatible xml files can be found here: http://www.adlnet.org/index.cfm?fuseaction=DownFile&libid=641&bc=false (i used the latest snapshots) A typical root element of a manifest file looks like this: <manifest identifier="photo-MANIFEST-remediation" version="1.3" xmlns="http://www.imsglobal.org/xsd/imscp_v1p1" xmlns:adlcp="http://www.adlnet.org/xsd/adlcp_v1p3" xmlns:adlseq="http://www.adlnet.org/xsd/adlseq_v1p3" xmlns:imsss="http://www.imsglobal.org/xsd/imsss" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.imsglobal.org/xsd/imscp_v1p1 imscp_v1p1.xsd http://www.adlnet.org/xsd/adlcp_v1p3 adlcp_v1p3.xsd http://www.adlnet.org/xsd/adlseq_v1p3 adlseq_v1p3.xsd http://www.imsglobal.org/xsd/imsss imsss_v1p0.xsd"> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=29798&edit=1

« previous php.bugs (#65091) next »