Support

Account

Home Forums Front-end Issues How do the date of publication by a front-end form? Reply To: How do the date of publication by a front-end form?

  • Hi @buylov

    You can add a style to hide this field using the “acf/admin_head” hook. Something like this I think:

    function my_acf_admin_head() {
    	?>
    	<style type="text/css">
    
    		.post-php .acf-field-5694a485a4a99, .post-new-php .acf-field-5694a485a4a99 {display:none;}
    
    	</style>
    	<?php
    }
    
    add_action('acf/input/admin_head', 'my_acf_admin_head');

    To make it use your site’s timezone, kindly change “post_date” to “post_date_gmt”. This page should give you more idea about it: https://codex.wordpress.org/Function_Reference/wp_insert_post.