I need to limit period od post publication - admin type date, for example, 30.05.2016 in custom fields and then i need to hide custom posts with this date less, then today date
How i can do this?
Have you looked into expire plugins ? https://wordpress.org/plugins/search.php?q=expire
finally wordpress.org/plugins/post-expiring seems to have done the job.
wp_schedule_event()
and while hooking into this event, verify each post's submission date and get the time difference. If the difference is greater than your length e.g 1month, then usewp_update_post()
to set the status to pending or something else..