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

learn more… | top users | synonyms

1
vote
2answers
88 views

Do multiple jobs on date change without WordPress cron job

I m trying to randomize several posts on my client's site which are on different pages , everyday. So I wrote a function which returns true on date change, and if does, I randomize the post ids and ...
0
votes
2answers
22 views

Pages for Cron use Only?

so I've got a bunch of custom page templates that are scripts that are meant to be run by cron to update various things on my wordpress site, there are not meant to be viewed by regular site users. ...
0
votes
2answers
216 views

WP Cron doesn't save <iframe> or <object> in post body

I am using wp_cron to auto grab posts from a remote website and save them in my wp db. NOTICE! I am executing my code from my plugin, not from my template functions.php or somewhere else. I have my ...
5
votes
1answer
177 views

wp_schedule_event won't accept args

I'm trying to schedule event on hourly basis but it doesn't work. Why, I can't understand. Here is a function that i use to schedule event. add_action( 'scheduled_update_feeds', 'update_feeds', 10, ...
2
votes
1answer
98 views

Send email daily from WordPress site

I customized a calendar plugin which shows today's birthdays and current month's list of wedding anniversaries in the home page of the site. I wrote a code in that plugin's displaying page using ...
2
votes
1answer
185 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
1answer
252 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
1answer
180 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
1answer
1k views

Wordpress schedule posting not working

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 ...
1
vote
1answer
259 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'); ...
0
votes
1answer
68 views

wp-cron still running even though DISABLE_WP_CRON is true

I have created a cron job to run wp-cron.php for me but I am seeing in my FPM logs where it's still running. From what I understand, is that with the cron job it wouldn't be hitting FPM to create any ...
0
votes
1answer
100 views

What is the use of wp_schedule_event hook?

I want to do a cron(executes function at specific time, like email,db backup etc) job. I searched in wordpress, i got this wp_schedule_event Here they say it will execute job when someone visits ...
0
votes
1answer
201 views

set post to draft after set period based on post_modified date

I have a custom post type for a users profile page. My client wants all users to update their profile at least once a month. So we want their profile (custom post) to be automatically set to draft ...
0
votes
1answer
66 views

Regenerating array key for wp_schedule_event args

I've been working on this the last day with no luck. Is there any way to update a stored args array key for an event scheduled? Reason I ask is I have array args that look like this when scheduling a ...
0
votes
1answer
308 views

wp_schedule_event in a class

This is my (stripped down) plugin, in OOP: <?php /* Plugin Name: Cron Test Plugin URI: http://www.mywebsite.com/ Description: Test Version: 1.0 Requires at least: 3.0 */ class CronTest { public ...
0
votes
1answer
198 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
193 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
65 views
+50

WP Cron and wp_insert_post

I'm trying to insert posts using a cron job, but I keep running into errors where WP is missing functions (is_user_logged_in, wp_get_current_user). Is there a proper way to run wp_insert_post using a ...
1
vote
0answers
53 views

Get frequency of scheduled event

How do I get the frequency of a scheduled event? I am writing a plugin, that would do something in a user defined schedule. The way I am trying to do this, is creating a custom cron schedule, which ...
1
vote
0answers
70 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
157 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
203 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
21 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') && ...
0
votes
0answers
23 views

Cron job not firing

I'm having this problem where cron jobs doens't seem to post delayed posts.. I'm using this cron job wget -O /dev/null http://domain.com/wp-cron.php?doing_wp_cron Am i doing something wrong?
0
votes
0answers
14 views

Cron job to delete post by title

I've searched a lot and I didn't find nothing that could help me. So, I want a cron job to automatically delete posts that have no title. Why I want that? I have a IFTTT recipe that automatically post ...
0
votes
0answers
22 views

Scheduled event occurring each page load, but supposed to happen daily

I have a scheduled event that is supposed to occur only once a day at 12am. However, for some reason my scheduled event is happening on each page load and I can't figure out why. The default ...
0
votes
0answers
32 views

Expire a post with meta_value after two weeks

I am trying to use the below code to query for some posts and then change a meta_value in order to "expire" it after two weeks time. I can't get this to work and it's difficult to test since I can ...
0
votes
0answers
41 views

custom cron interval is not working

I am trying to create custom interval for cron schedule with below code but it is not working, function cronschedules($schedules) { $schedules['custom'] = array( 'interval' => 36000, // seconds ...
0
votes
0answers
48 views

WP Cron debug issue - running on staging, not on live

I realised a plugin's wordpress cron wasn't running on my live site, so I installed WP Debug Cron to investigate the issue. All the custom and core events show Next Execution as being in the past. In ...
0
votes
0answers
52 views

wp-cron.php - timeout

I found via Query Monitor plugin, that there is some HTTP request error during page load. I looked at the error table, and here I found that problem is with this: FULL_IMAGE How can I delete this ...
0
votes
0answers
109 views

WP-Cron tasks scheduled but not running

I'm working on a particularly large WordPress multisite network, and have been struggling with WP-Cron. It seems that WP-Cron tasks are being scheduled, but not run. The WP-Cron tasks are not being ...
0
votes
0answers
82 views

Cron Lock Timeout, when to use?

When is it a good idea to use this constant in relation to WordPress Cron? WP_CRON_LOCK_TIMEOUT
0
votes
0answers
25 views

Break a Wordpress function to run in patches and re-continue

I am new to PHP and coding and I am really not a coder but I try to modify and use existing codes. I have a function which I am trying to run when needed for all users within Wordpress to do an ...
0
votes
0answers
64 views

wp_schedule_single_event running twice

I have set up a meta box with a checkbox, so when checked and the post is saved, a scheduled event is registered to send an email to all users (around 1200) in the background. Sometimes the emails ...
0
votes
0answers
210 views

Using wp_cron with wp_mail to send bulk email

I am working on a custom plugin to send recurring invoices on the 1st of every month. So far, the plugin is working pretty well. It creates new invoices for each user based on their order and does ...
0
votes
0answers
28 views

Daily class register with monthly invoicing

I'm about to take on the task of creating a daily class register the features of which I have listed below. I am mostly a novice when it comes to wordpress development and I can do some PHP ...
0
votes
0answers
31 views

Trigger scheduled cron events upon logged-in user visit

I am building an entirely private site where only the wp-login.php page can be viewed by non-logged-in users. After an entire day of debugging I've come to realize that non-logged-in user visits are ...
0
votes
0answers
49 views

WooCommerce Emails Firing Multiple TImes

I am having a problem with my WooCommerce install where order update emails (which I think are scheduled using WP Cron??) are fired multiple times - some times as many as 7 or 8. Would it be WPCron ...
0
votes
0answers
35 views

Wordpress Cron Job Counting Up and Not Down

I'm having a strange problem in which a WP Cron Job is counting "up" and not "down". Thus the job never runs. What I mean exactly should be clear from these outputs: [19-Sep-2013 23:33:51 UTC] ...
0
votes
0answers
47 views

Reoccurring cron request

It appears that somehow my plugin on some wordpress installations causes a never ending stream of cron requests to occur. I believe the only place that we use code that interacts with cron is when we ...
0
votes
0answers
32 views

WPMU schedule doesn't execute actions

Here's a simple event that is correctly scheduled to be executed daily. Unfortuantely, it doesn't execute delete_old_users() function daily. It is supposed to delete users older than a certain date. ...
0
votes
0answers
55 views

Update members data daily by a function

I use a function to update data (likes, +1, views, point, posts..v.v.) for all members on site Once Daily. So it may be can not run with >2000 members and >5000 posts. Only display a blank page. The ...
0
votes
0answers
46 views

Plugin Hooks Not Shown in WP Cron Jobs

I have installed a WordPress backup plug-in. This plug-in has several hooks. Some of those hooks should activate right after I trigger the backup tasks. But the problem is, after I start that plugin ...
0
votes
0answers
105 views

Wordpress can't seem to handle tens of thousands of scheduled posts? Cron Breaks

I have a website listing doctors in the us. I'm spreading out the posts over 2 years, but I have about 2.8 million doctors to list. Right now I'm adding the post automatically via a custom script, and ...
0
votes
0answers
42 views

Reading csv from specific directory and insert it to custom post type (cron job)

Need a comprehensive cron job script to read .csv data uploaded regularly to specific folder. Will insert data to custom post type only if csv exist base on cron job current date. Any suggestion of ...