Dateformat cannot be changed in Beaver Builder - Custom fields in combination with Pods


When i create a custom field with date in Pods and want to display it in a Beaver Builder Powerpack module… it will put the year in front. But whatever dateformat i use, it will not change. Please help.

I already tried:

  • Changing the date formats in Pods
  • Changing the dateformat of Wordpress
  • Changing the date format in the custom field.

post:custom_field only outputs whatever the field is, there is no format switch, it is not a date field. So the shortcode is literally just outputting the field

Thanks for the answer. What is a way i can do this? From custom field to date in there?

Well whatever you are using to set that field thats where you need to make sure its in the right format, then the custom_field shortcode will be able to output it.

Or you can create your own shortcode something like this

add_shortcode( 'custom_field_date', function( $atts ) {
	global $post;
	$atts = shortcode_atts( array(
		'format' => 'Ymd',
		'key'    => '',
	), $atts );
	if ( $atts['key'] ) {}
	return gmdate( $atts['format'], strtotime( get_post_meta( $post->ID, $atts['key'], true ) ) );

Then just use [custom_field_date]