[wp-hackers] ALTERNATE_WP_CRON... Is it worth it?
Dion Hulse (dd32)
wordpress at dd32.id.au
Tue Oct 9 23:25:39 UTC 2012
For the very specific case of the following error:
Warning: fopen(http://localhost/wp/wp-cron.php?doing_wp_cron)
[function.fopen]: failed to open stream: HTTP request failed!
One option to fix it, is to disable the faulty HTTP transport which
isn't doing it's job on the server (usually it's caused by a bad
configuration, but some linux distro PHP builds are known to cause it
as well) by adding the following in a mu-plugin (or the theme
functions.php I guess)
add_filter( 'use_streams_transport', '__return_false' );
It has the downside that it may stop ALL outgoing requests if the
server doesn't support cURL and fsockopen also doesn't work - but
usually at least one of these is available on the server..
I usually suggest hitting the Plugin install page, if you can search
for a plugin after adding the above, all your problems should
hopefully disappear.. if you can't browse plugins, you'll have to
remove the above line of code and curse at the server again..
On 9 October 2012 17:57, Micky Hulse <mickyhulse.lists at gmail.com> wrote:
>
> Hi Ben!
>
> On Tue, Oct 9, 2012 at 2:52 PM, Ben Lobaugh <lists at lobaugh.net> wrote:
> > P.S. If you are forced to use the work around you could setup one of the
> > dozens of free ping services to hit your site in an attempt to counter the
> > bad behavior
>
> Interesting... I hate to sound like a dunce, but could you elaborate
> just a bit further? :)
>
> Thanks!!!
>
> --
> http://hulse.me
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
More information about the wp-hackers
mailing list