wp-cron refers to a WordPress subsystem that allows for the scheduled execution of code

learn more… | top users | synonyms

2
votes
1answer
18 views

Scheduling a task using class methods

I need to implement a scheduled task in my plugin, and I tried to follow the examples in the documentation, passing one of class methods as the target. I installed Cron Manager plugin, and I see that ...
1
vote
1answer
50 views

wp_next_scheduled returning a past timestamp

So, here is my entire code in wp_content/plugins/my_plugin/my_plugin.php : register_activation_hook(__FILE__, 'comunity_mails_activation'); add_action('check_mails_to_send', 'do_this_daily'); ...
1
vote
1answer
115 views

How to set up WP Cron in this scenario

I wanted to use Wordpress built in WP Cron to update currency rates daily. I use this function currently, require_once(WP_PLUGIN_DIR . '/autocurupdate/currencyexchange_class.php'); $cx=new ...
0
votes
1answer
43 views

wp-cron: freeze at “now”

sorry for the silly question. Briefly I have a wp (v. 3.5.1) blog using a heavily modified (by myself) theme. Everything works fine except for wp-cron. Listed jobs appears in (for instance) crontrol ...
0
votes
1answer
168 views

Wordpress schedule posting not working, if i added define('DISABLE_WP_CRON', false); how do i fix it?

I have Wordpress 3.5.1 and I use Bluehost hosting service. When I schedule posts after that time passed, WP posts dashboard shows "Missed schedule" message under the date. Then I checked my ...
0
votes
1answer
101 views

How do you make a custom post type items automatically delete items 3 months after publication?

I'd like somer code that I can place in my functions.php file that will only modify the specified custom post type. I have already tried several plugins, but all of them have more features than I ...
2
votes
0answers
41 views

WP Cron emails not working

Running wp 3.5.1. I have 2 plugins that work in part. They do everything nice. If I click to send emails, they send the emails. However the scheduled emails are not being sent. The plugins are: ...
2
votes
0answers
89 views

Change post status based on meta value

I have this cron set up to trash posts x days after it is posted. This works. Edit: Added my answer to my question. add_action( 'wp', 'do_trash_ads' ); function do_trash_ads() { if ( ! ...
2
votes
0answers
75 views

Scheduled Posts and wp-cron - Why don't scheduled posts publish if too old?

I notice that the documentation for wp_schedule_single_event mentions the following:- The action will fire off when someone visits your WordPress site, if the schedule time has passed. However ...
1
vote
0answers
21 views

Wordpress daily cron is executing more frequently than once a day

I have a wp cron job scheduled based on what's in the options. In this case its schedule daily. add_action('init', function(){ if( !wp_next_scheduled('product_posting_cron') ){ ...
1
vote
0answers
59 views

wp_schedule_single_event function not working

I am testing the wp_schedule_single_event function and it is currently not working on my upgraded version of wordpress. It looks like the event is being scheduled but the code in my hook is never ...
1
vote
0answers
124 views

Is it possible to use `wp_schedule_event` with real cronjobs?

I hate the way Wordpress Cron Jobs run, so I disabled them: define('DISABLE_WP_CRON', true); and want to run a real cron job instead: wget http://www.myserver.com/wp-cron.php > /dev/null ...
1
vote
0answers
14 views

How ( and mostly at what time ) can i prevent the alternate cron from running?

I'm using the alternate cron version, but i need to prevent it from running on some calls, how can i do this? In the cron.php file i've seen on line 225 if ( defined('ALTERNATE_WP_CRON') && ...
1
vote
0answers
39 views

Cron job not run on activation

The code i am pasting is supposed to run the function exporting once on activation of plugin and then hourly. But it doesn't run on activation nor hourly. I do see it in the list of cron jobs that are ...
0
votes
0answers
15 views

Scheduling daily refresh of posts

So here's my situation: I'm using AmazonSimpleAdmin to display products using the Amazon API. I have one product per post. The API limits 1 request per second. Meaning my front page can only have one ...
0
votes
0answers
29 views

Missed Schedule alert on dashboard?

Is there a way to pull a list of posts that have missed their schedule and display them on the dashboard? I'm having an issue with missed schedule posts sometimes and don't want to use the plugin ...
0
votes
0answers
27 views

wp_schedule_event attempt causes T_CONSTANT_ENCAPSED_STRING error

I'm developing a plugin and am trying to set up a recurring event for it. However, even putting the function that I'm about to link to an activation hook in my file causes wordpress to throw this ...
0
votes
0answers
83 views

“Wordpress Firewall 2” Causes 403 Forbidden Error in wp-cron.php Thwarting “BackUpWordPress”

My web sites have been hacked in the past, so I set up certain security features on each site like a firewall plugin, for instance. In fact, the week after I forgot to re-enable the firewall when ...
0
votes
0answers
22 views

wp_schedule_single_event works on local but not on live

I'm using the wp_schedule_single_event() function to email an author designated "Important Post" to all users of a site one second after saving the post (so that it runs in the background and the ...
0
votes
0answers
94 views

Debugging a WPCron function

I'm trying to run a WP cron job which, every hour, checks for recently created/updated posts and runs a filter on them. if ( $post->post_type == "species" ) { $meta = get_post_custom( ...