Support

Account

Home Forums General Issues Datepicker: wrong format is displaying Reply To: Datepicker: wrong format is displaying

  • @matthewbivins sorry for the late reply, just got back in town. Here’s the code that worked for me. It can be improved upon but did the job. Best of luck.

    <?php 
    	if(get_field('deadline'))
    		{
    			$date = DateTime::createFromFormat('Ymd', get_field('deadline'));
    			echo '<li><strong>Deadline: </strong>';
    			echo $date->format('F j, Y');
    			echo '</li>';
    		}	 	 			 	 
    ?>