WP Automatic and custom field data

Floccer

Regular Member
Joined
Mar 2, 2019
Messages
365
Reaction score
163
Hi,

I need help with wp automatic and its "Add Custom Fields/Taxonomies/Excerpt to the created posts" -part as I want data to custom field in post.

I need to add expiry date to post and I can add date to custom field but is it possible to somehow add 30 days from the publishing date?
WP automatic has [publish_date] that can be used to insert the current date in format 2023-02-22 but I don't know if it's possible to edit that date.
Another idea I had was to make my own variable/function that would change the month of the current date from 2023-02-22 but I cannot find the file where these are stored.

wp-automatic/p_metabox.php file contains $allowed_tags where I found array and [publish_date] but I don't know where this data is pulled.

 
Yea. I managed to add my own custom variable.
In the wp-automatic/core.feeds.php I founded the $publish_date variable.

Below that I added
PHP:
$next_month = date('Y-m-d', strtotime('+1 month'));

And in later part I added new variable under the ['publish_date'] part
PHP:
$res ['publish_date'] = $publish_date;
$res ['next_month'] = $next_month;

Now I can apply [next_month] to post in the custom fields section. This isn't visible in the campaign page but that doesn't matter.
 
Back
Top