Wordpress - Force publish future event

Developer
Size
1,403 Kb
Views
20,240

How do I make an wordpress - force publish future event?

What is a wordpress - force publish future event? How do you make a wordpress - force publish future event? This script and codes were developed by Cory Schadt on 19 October 2022, Wednesday.

Wordpress - Force publish future event Previews

Wordpress - Force publish future event - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Wordpress - Force publish future event</title>
</head>
<body> function onetarek_prevent_future_type( $post_data ) {
if ( $post_data['post_status'] == 'future' && $post_data['post_type'] == 'YOURPOSTYPEHERE' )#Here I am checking post_type='post' , you may use different post type and if you want it for all post type then remove "&& $post_data['post_type'] == 'post'"
{
$post_data['post_status'] = 'publish';
}
return $post_data;
}
add_filter('wp_insert_post_data', 'onetarek_prevent_future_type');
remove_action('future_post', '_future_post_hook');
</body>
</html>
Wordpress - Force publish future event - Script Codes
Wordpress - Force publish future event - Script Codes
Home Page Home
Developer Cory Schadt
Username coryschadt
Uploaded October 19, 2022
Rating 3
Size 1,403 Kb
Views 20,240
Do you need developer help for Wordpress - Force publish future event?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Cory Schadt (coryschadt) Script Codes
Create amazing Facebook ads with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!