Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.7.2

Bug #12568 documentation bug
Submitted: 2007-12-02 10:16 UTC
From: till Assigned: lukasfeiler.com
Status: Closed Package: XML_Query2XML (version 1.5.0)
PHP Version: 5.2.3 OS: FreeBSD
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 4 + 49 = ?

 
 [2007-12-02 10:16 UTC] till (Till Klampaeckel)
Description: ------------ Running this example: http://pear.php.net/package/XML_Query2XML/docs/1.5.0/XML_Query2XML/XML_Query2XML.html ... gives me an error: Fatal error: Call to private XML_Query2XML::__construct() from invalid context in /usr/home/till/public_html/MDB2-test.php on line 10 Looking at the file (XML/Query2XML.php), the __construct is really private? But no documentation or so exists on how to not call it. I just installed this through pear install XML_Query2XML, and I have the latest installed. Test script: --------------- <?php require_once 'MDB2.php'; require_once 'XML/Query2XML.php'; $dsn = 'mysqli://root:@localhost/mysql'; $query2xml = new XML_Query2XML(MDB2::factory($dsn)); ?>

Comments

 [2007-12-02 12:12 UTC] till (Till Klampaeckel)
Figured out by now that I need to call Query2XML::factory() instead of a new Query2XML(), but this bug exists in all your examples. I am not sure if this bug exists on your sourceforge site as well, but it would be cool if you update the docs on PEAR because this is where most people go to when they click "documentation" on the package homepage. Also, it would be great if you could split Query2XML.php into multiple files, e.g. all the exceptions, the abstract, etc.. This will soon become a part of PHP-CS anyway.
 [2007-12-03 03:54 UTC] lukasfeiler (Lukas Feiler)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better. Thanks for reporting this! FYI: This bug existed in two of the examples contained in the API docs. The tutorial at sf.net, i.e. the "End-user Documentation" does not contain this bug. Are we really about to adopt a "one (public?) class per file" rule?