Maybe someone will make use of it, I had a similar problem and the solution was to call time() instead of current_time( 'timestamp' ) as the first argument of wp_schedule_event().
So it should look like this: wp_schedule_event( time(), 'custom_interval', 'custom_hook' );
I tried to find a difference between time and current_time(‘timestamp’), but they appear to return the same output, int unix time.
Related Posts:
- Which action for triggering cron “wp”or “init”?
- wp_schedule_event in a class
- WP Cron – Run Cron after evey 15 minutes at a specific time for the next three hours
- Using wp_cron with custom time interval and the register activation hook
- WordPress scheduled task is called but not executed
- Problem creating cron job wordpress
- How Do I Make WordPress Run an Event Every Day?
- How can I change the frequency of a scheduled event?
- Hourly WP schedule, do I need at least 1 visitor hourly?
- WP Cron doesn’t save or in post body
- Is there any background process that I can run from plugin without depending on page hits on a website without affecting page-load speed?
- WordPress cron running twice
- Scheduling a task using class methods
- What is minimum time interval for which a cron be scheduled?
- Will cron job run if page loaded is being served from cache?
- Use wp_set_post_terms() instead of wp_insert_post()
- Programmatically detect if wp-cron is disabled?
- How to schedule a cron job in plugin without waiting for page load request?
- How to perform a heavy and long process in cron jobs?
- WordPress daily cron is executing more frequently than once a day
- wp-cron and execution of code in is_admin() included script
- How to Trigger WP CRON at Local Timestamp?
- WP Cron being triggered but not working as expected
- wp_schedule_event() set daily, but processed every second
- Will I get an error if I try unscheduling a WP Cron scheduled task that wasn’t scheduled?
- Looking for a better way to initiate cron job
- WordPress plugin cron working only if admin is logged in
- How to make a cronjob type plugin
- wp_schedule_single_event is set correctly but sometimes not fired
- How to Run Plugin on Server Without Web Browser
- Plugin with functions inside a class & how to trigger WP CRON
- How and when would I implement some code which would take data from one part of the Db and put it in another?
- WP Cron as Fast as WordPress AJAX?
- Detect each active instance of a widget
- What is the use of wp_schedule_event hook?
- Can wp_schedule_single_event be used to run background proccess?
- Call do_action() within WordPress cronjob
- Running one-off cron jobs when WP_DISABLE_CRON is true: can I hit /wp-cron.php?
- wp cron does not run when i am not logged in to wp admin
- Unit testing for plugin development
- How would I create a plugin for my shortcodes?
- How does uninstalling WordPress plugins work?
- Sharing common functionality (functions, template parts) between plugins and themes?
- How can I turn a custom wordpress page into a product page?
- WP and object persistence (or lack thereof)
- Bad Request in AJAX
- Shortcode not appearing when used as post content in wp_insert_post() or possibly, shortcode not being registered at all
- Creating two tables in database on activation hook
- Adding Custom CSS with PHP
- How to remove/replace current page template?
- How to receive notification of deprecated API elements and functions?
- Using password protection to load different page elements?
- Change reminder email date to 14 days before
- wp_remote_post not working with admin-post.php
- WordPress Own Rewrite Rules
- Default media uploader is not showing in wordpress website
- Load custom translation in custom plugin fails
- Buddy Press restrict the capability to edit users
- “Headers Already Sent” Nightmare on Plugin
- Developing a plugin where users can edit entries saved in database
- How to create session for user which is not an admin user
- wordpress plugins with add-ons
- oneOf two possible objects in WP REST API?
- How to get the value entered in the input field in wordpres
- Sanitize and Save metabox values
- Help interpreting @wordpress/create-block-tutorial-template usage error
- Leveraging Core Functionality in Icon Upload Plugin [closed]
- WooCommerce adds a newline symbol (\n) between email recipients
- Upload to a specific media folder created by FileBird Lite
- How can I add a custom button to the post editor?
- How to use register_setting()
- What’s wrong in the WordPress Meta Box Generator code?
- add category id to option name when adding an option on edit_category
- esc_url, esc_url_raw or sanitize_url?
- React Plugin Settings Page Localization
- Is it within WordPress guidelines to update another plugin’s database fields from my own plugin? [closed]
- Block Development: hamburger module throwing error in save function
- How can I chanage the user for the composer container in wp-env?
- Adding a navigation with wp_nav_menu() to a custom block in the site editor
- Why isn’t custom sidebar panel not showing up in the Gutenberg Editor?
- Ninja Forms: Front-End Forms, Post ID?
- Allow HTML in product attributes and variation for WooCommerce
- How do I modify the error code array used by “shake_error_codes” filter?
- How do I add multiple custom menu Woo-commerce my account page?
- How to move custom gutenberg block controls from settings to styles tab?
- How can I obtain an option (get_option) inside a block viewScript?
- 2 Domains pointing to SIngle WordPress , issues with links
- How can I space out images when adding to a post without HTML/CSS/JS?
- How to apply a javascript code on certain parts of elementor made pages?
- Hide menu items from not logged in users
- How to generate frontend page with callback?
- move useState variable from edit.js to save.js. How do I do that?
- Page jumps to top
- Endpoint returning a 404
- Is there a hook for updated image metadata upon using image editor?
- WordPress Block with Interactivity API e Preact Component
- adding an options menu that allows saving multiple sets of said options
- How to assign to each output values from foreach loop to a meta_key?
- Select a Text for CSS
- WordPress – Filter users list count