[wp-trac] [WordPress Trac] #16565: Several E_NOTICE when using IXR_Client
WordPress Trac
wp-trac at lists.automattic.com
Tue Feb 15 09:45:10 UTC 2011
#16565: Several E_NOTICE when using IXR_Client
--------------------------+------------------------------
Reporter: tillkruess | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.0.5
Severity: normal | Resolution:
Keywords: |
--------------------------+------------------------------
Changes (by nacin):
* keywords: reporter-feedback =>
* severity: major => normal
Old description:
> {{{
> POST /xmlrpc.php HTTP/1.0
> Host: foobar.com
> Content-Type: text/xml
> User-Agent: The Incutio XML-RPC PHP Library -- WordPress/3.0.5
> Content-Length: 281
>
> <?xml version="1.0"?>
> <methodCall>
> <methodName>pingback.ping</methodName>
> <params>
> <param><value><string>http://foo.com/</string></value></param>
> <param><value><string>http://bar.com/</string></value></param>
> </params></methodCall>
> HTTP/1.1 200 OK
> Date: Tue, 15 Feb 2011 07:28:38 GMT
> Server: Apache/2.2.16
> X-Powered-By: PHP/5.3.5
> Connection: close
> Content-Type: text/html
>
> <br />
> <b>Notice</b>: Undefined index: path in <b>/wp-includes/rewrite.php</b>
> on line <b>302</b><br />
> <br />
> <b>Notice</b>: Trying to get property of non-object in <b>/wp-
> includes/rewrite.php</b> on line <b>341</b><br />
> <br />
> <b>Notice</b>: Undefined index: HTTP_REFERER in <b>/wp-
> content/plugins/akismet/akismet.php</b> on line <b>300</b><br />
> <br />
> <b>Notice</b>: Undefined index: user_ID in <b>/wp-
> content/plugins/akismet/akismet.php</b> on line <b>306</b><br />
> <br />
> <b>Notice</b>: Undefined index: comment_author_email in <b>/wp-
> includes/comment.php</b> on line <b>1200</b><br />
> <br />
> <b>Notice</b>: Undefined index: comment_author_email in <b>/wp-
> content/plugins/akismet/akismet.php</b> on line <b>262</b><br />
> <br />
> <b>Warning</b>: Cannot modify header information - headers already sent
> by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
> /class-IXR.php</b> on line <b>395</b><br />
> <br />
> <b>Warning</b>: Cannot modify header information - headers already sent
> by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
> /class-IXR.php</b> on line <b>396</b><br />
> <br />
> <b>Warning</b>: Cannot modify header information - headers already sent
> by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
> /class-IXR.php</b> on line <b>397</b><br />
> <br />
> <b>Warning</b>: Cannot modify header information - headers already sent
> by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
> /class-IXR.php</b> on line <b>398</b><br />
> <?xml version="1.0"?>
> <methodResponse>
> <params>
> <param>
> <value>
> <string>Pingback from http://foo.com/ to http://bar.com/
> registered. Keep the web talking! :-)</string>
> </value>
> </param>
> </params>
> </methodResponse
> }}}
New description:
{{{
POST /xmlrpc.php HTTP/1.0
Host: foobar.com
Content-Type: text/xml
User-Agent: The Incutio XML-RPC PHP Library -- WordPress/3.0.5
Content-Length: 281
<?xml version="1.0"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param><value><string>http://foo.com/</string></value></param>
<param><value><string>http://bar.com/</string></value></param>
</params></methodCall>
HTTP/1.1 200 OK
Date: Tue, 15 Feb 2011 07:28:38 GMT
Server: Apache/2.2.16
X-Powered-By: PHP/5.3.5
Connection: close
Content-Type: text/html
<br />
<b>Notice</b>: Undefined index: path in <b>/wp-includes/rewrite.php</b>
on line <b>302</b><br />
<br />
<b>Notice</b>: Trying to get property of non-object in <b>/wp-
includes/rewrite.php</b> on line <b>341</b><br />
<br />
<b>Notice</b>: Undefined index: HTTP_REFERER in <b>/wp-
content/plugins/akismet/akismet.php</b> on line <b>300</b><br />
<br />
<b>Notice</b>: Undefined index: user_ID in <b>/wp-
content/plugins/akismet/akismet.php</b> on line <b>306</b><br />
<br />
<b>Notice</b>: Undefined index: comment_author_email in <b>/wp-
includes/comment.php</b> on line <b>1200</b><br />
<br />
<b>Notice</b>: Undefined index: comment_author_email in <b>/wp-
content/plugins/akismet/akismet.php</b> on line <b>262</b><br />
<br />
<b>Warning</b>: Cannot modify header information - headers already sent
by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
/class-IXR.php</b> on line <b>395</b><br />
<br />
<b>Warning</b>: Cannot modify header information - headers already sent
by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
/class-IXR.php</b> on line <b>396</b><br />
<br />
<b>Warning</b>: Cannot modify header information - headers already sent
by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
/class-IXR.php</b> on line <b>397</b><br />
<br />
<b>Warning</b>: Cannot modify header information - headers already sent
by (output started at /wp-includes/rewrite.php:302) in <b>/wp-includes
/class-IXR.php</b> on line <b>398</b><br />
<?xml version="1.0"?>
<methodResponse>
<params>
<param>
<value>
<string>Pingback from http://foo.com/ to http://bar.com/
registered. Keep the web talking! :-)</string>
</value>
</param>
</params>
</methodResponse
}}}
--
Comment:
`Undefined index: path in /wp-includes/rewrite.php on line 302`
That one is legitimate. The rest are possibly akismet. Not sure what would
cause line 341. (fyi, on 3.0.5 tag.)
home_url() is not trailing-slashed. That means that parse_url() won't set
a path.
Changing home_url() to `home_url('/')` fixes this. There are possibly
other instances in the codebase where we parse_url() home_url().
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16565#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list