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

Request #15028 URL with trailing slash gives error
Submitted: 2008-11-14 14:59 UTC
From: mecu Assigned: cweiske
Status: Closed Package: Services_Blogging (version 0.2.2)
PHP Version: 5.2.5 OS: Linux
Roadmaps: (Not assigned)    
Subscription  


 [2008-11-14 14:59 UTC] mecu (Michael Hoppes)
Description: ------------ Putting a trailing slash for the URL when defining the blog setup info causes an error. Removing the trailing slash eliminates the error. Test script: --------------- require 'Services/Blogging.php'; $bl = Services_Blogging::factory( 'Blogger', //driver name 'login', 'password', 'http://myblog.blogspot.com/', null ); Expected result: ---------------- I would expect the package to eliminate the trailing slash automatically, as to not then cause this error. Actual result: -------------- An error occurred while trying to run your query. Error message: XML_RPC_Client: Connection to RPC server bcsfanpoll.blogspot.com/:80 failed. A more detailed error description: Fatal error: Uncaught exception 'Services_Blogging_Exception' with message 'XML-RPC communication error: ' in /home/content/e/v/e/everyonepoll/html/pear/PEAR/Services/Blogging/XmlRpc.php:34 Stack trace: #0 /home/content/e/v/e/everyonepoll/html/pear/PEAR/Services/Blogging/Driver/Blogger.php(97): Services_Blogging_XmlRpc::sendRequest(Object(XML_RPC_Message), Object(XML_RPC_Client)) #1 /home/content/e/v/e/everyonepoll/html/pear/PEAR/Services/Blogging.php(73): Services_Blogging_Driver_Blogger->__construct('hoppes@gmail.co...', 'VX9aao!9', 'http://bcsfanpo...', NULL) #2 /home/content/e/v/e/everyonepoll/html/blog.php(12): Services_Blogging::factory('Blogger', 'login', 'password', 'http://myblog...', NULL) #3 {main} thrown in /home/content/e/v/e/everyonepoll/html/pear/PEAR/Services/Blogging/XmlRpc.php on line 34

Comments

 [2008-11-14 15:07 UTC] mecu (Michael Hoppes)
I've already changed my password since I missed changing it when I submitted this. If anyone can remove that information, I would appreciate it.
 [2008-11-17 00:43 UTC] doconnor (Daniel O'Connor)
I get different errors, but errors all the same. For the first case: clockwerx@clockwerx-desktop:~/pear$ php bug-15028.php exception 'Services_Blogging_Exception' with message 'XML-RPC communication error: php_network_getaddresses: getaddrinfo failed: Name or service not known' in /usr/share/php/Services/Blogging/XmlRpc.php:34 Stack trace: #0 /usr/share/php/Services/Blogging/Driver/Blogger.php(97): Services_Blogging_XmlRpc::sendRequest(Object(XML_RPC_Message), Object(XML_RPC_Client)) #1 /usr/share/php/Services/Blogging.php(73): Services_Blogging_Driver_Blogger->__construct('login', 'password', 'http://myblog.b...', NULL) #2 /home/clockwerx/pear/bug-15028.php(10): Services_Blogging::factory('Blogger', 'login', 'password', 'http://myblog.b...', NULL) #3 {main} then: Notice: Undefined index: lv in /usr/share/php/XML/RPC.php on line 551 and XML error: > required at line 4 exception 'Services_Blogging_Exception' with message 'Invalid return payload: enable debugging to examine incoming payload' in /usr/share/php/Services/Blogging/XmlRpc.php:38 Stack trace: #0 /usr/share/php/Services/Blogging/Driver/Blogger.php(97): Services_Blogging_XmlRpc::sendRequest(Object(XML_RPC_Message), Object(XML_RPC_Client)) #1 /usr/share/php/Services/Blogging.php(73): Services_Blogging_Driver_Blogger->__construct('login', 'password', 'http://myblog.b...', NULL) #2 /home/clockwerx/pear/bug-15028.php(21): Services_Blogging::factory('Blogger', 'login', 'password', 'http://myblog.b...', NULL) for the second. Use of Net_URL would handily fix this
 [2008-11-29 12:14 UTC] cweiske (Christian Weiske)
Technically this is a feature request, because the path component clearly has an own parameter. Nevertheless I added some code to work around such user errors. Will be released today.