-
-
I used gravatars2 plugins to support my new sexy theme. There is some minor issue (throw fatal Error in PHP5.1) with this WordPress plugin. I did asked them to updated it but till today’s this bug still exists with Gravatars2 plugins.
This “fatal error” or conflict happen if you had PHP 5 ( 5.0 > 5.1 above) with HTTPRequest Modules Installed.
Plugin could not be activated because it triggered a fatal error. Fatal error: Cannot redeclare class httprequest in /../wp-content/plugins/gravatars2.php on line 284
HTTPRequest Classname Conflict
It’s not that hard to fix this “Naming Conflicts”. All you need is “Search and Replace” HTTPRequest class name to different name (ie: _HTTPRequest, HTTP__Request) so it wont conflict with PHP HTTPRequest Standard Class. If you don’t know how to do this. Check the below lists. It wont take long.
- Open wp-content/plugins/gravatars2.php or http://www.my-domain-name.com/wp-admin/plugin-editor.php?file=gravatars2.php
- Find on line 284
class HTTPRequest
Replace with
class _HTTPRequest
- Next find on line 323
function HTTPRequest($url, $timeout)
Replace with
function _HTTPRequest($url, $timeout)
- Final step find on line 408
$hr = new HTTPRequest($url, $timeout);
Replace with
$hr = new _HTTPRequest($url, $timeout);
- Save or upload back to wp-content/plugins/
Thats all
Gravatars2
For the record - “Gravatar2 developer doesn’t give support without donation”.
Excerpt from Kip Bond at zenpax.com
I am no longer giving support for this plugin without a donation — it’s becoming repetitive and not very rewarding. You can email me (kip @ this website’s hostname (zenpax.com)) with your question, and I can tell you what minimum donation amount is sufficient per the difficulty of the question. Note that this donation in no way obligates me to any contractual duties. It’s mostly a way to make sure that people have exhausted their own efforts at resolving their own problems before asking for my support. ~kip Bond
I hope these would explain some curiosity.
tips to php developer: used class_exists before declaring any user define class.
Related Links
-
- December 26, 2007 at 7:41 pm
- January 6, 2008 at 5:41 am
- 0.3
- url
-
-
-
No Responses to “How to Fix Gravatars2 PHP5 HTTPRequest Fatal Error”
Trackback URL: Use the TrackBack url ↑ to ping this article. If your blog does not support Trackbacks you might want to leave a comment instead.
-
-
"write as if you were talking to a good friend (in front of your mother)."
.haveyoursay
Disclaimer: For any content that you post, you hereby grant to Kakkoi the royalty-free, irrevocable, perpetual, exclusive and fully sublicensable license to use, reproduce, modify, adapt, publish, translate, create derivative works from, distribute, perform and display such content in whole or in part, world-wide and to incorporate it in other works, in any form, media or technology now known or later developed. Some rights reserved.
-
The following "Code" are designed to protect you and other users of this site.
In order to keep these experiences enjoyable and interesting for all of our users, we ask that you follow the above guidlines.
be the first to comment.