creating a scheduled post with wp_insert
-
Hi, I import data from csv file.
I want to create posts programmatically, and using wp_insrt I cannot see a “scheduled” post-status.
I see.‘post_date’ => [ Y-m-d H:i:s ] //The time post was made.
‘post_date_gmt’ => [ Y-m-d H:i:s ] //The time post was made, in GMT.
‘post_status’ => [ ‘draft’ | ‘publish’ | ‘pending’| ‘future’ | ‘private’ | custom registered status ] //Set the status of the new post.If I use “future’ in my array, I do not get a scheduled post.. I just get a ‘published” post.
The wanted result is a scheduled post, say an hour from NOW !
Any help?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘creating a scheduled post with wp_insert’ is closed to new replies.