Page 1 of 1
install pear/xml problem
Posted:
16. March 2007 16:47
by mikev
xampp on windows does not automatically install pear/xml
in fact no pear packages are installed on mine.
pear install xml - doesn't work - throws an error -
"no release available for pear.php.net/xml
cannot initialize xml, invalid or missing package file"
what am i doing wrong? i can see pear/xml folder is full of the files i want to use - so it is there. i'd like to not hack it with custom xampp config paths for includes and such.
any help appreciated.
Posted:
16. March 2007 16:55
by Wiedmann
pear install xml - doesn't work - throws an error -
There is no PEAr package with the name "xml".
i can see pear/xml folder is full of the files i want to use
Now, what's your problem?
Posted:
16. March 2007 16:59
by mikev
// require PEAR classes
require_once 'PEAR.php'; // PEAR
require_once 'XML/Tree.php'; // PEAR
requiring pear.php works fine in xampp
requiring xml/tree.php doesnt
thats my problem
Posted:
16. March 2007 17:02
by mikev
There is actually a package called xml listed on the pear website
http://pear.php.net/packages.php?catpid=22&catname=XML
so it appears there is a package called xml for pear
AND pear install XML throws same error I noted above
Posted:
16. March 2007 17:03
by Wiedmann
Ah, now: You want use "XML_Tree".
First:
You have read the package description at "pear.php.net"?
Posted:
16. March 2007 17:10
by mikev
docs for XML_TREE suggest using XML_Serializer instead
but xampp still has not installed XML or XML_Serializer
pardon my ignorance, i'm new to pear, and am just looking for some help getting xampp configured like out test server.
Posted:
16. March 2007 17:13
by Wiedmann
- Code: Select all
but xampp still has not installed XML or XML_Serializer
One more: XML is ans was not a PEAr package.
XML_Serializer:
I've looked inside XAMPP 1.6.0 and can see this file:
\xampp\php\PEAR\XML\Serializer.php
Posted:
16. March 2007 17:22
by mikev
so I need to change my include statements to relative paths then
as opposed to "installing" packages with pear install <package>
a little counter-intuitive to me since "pear list" tells me "no packages are installed."
It might be worth noting that difference somewhere in the xampp/php/pear docs
Posted:
16. March 2007 17:54
by Wiedmann
so I need to change my include statements to relative paths
Just look at the PEAR documentation. e.g. XML_Serializer:
http://pear.php.net/manual/en/package.x ... amples.php--> The PEAR install directory is (and must be) in your PHP include_path. Thus you include the PEAR packages allways realtive to this PEAR install directory.
a little counter-intuitive to me since "pear list" tells me "no packages are installed."
Right. The PEAR command line installer is currently not really working in XAMPP.