Skip to content

Commit 605f034

Browse files
authored
Create gpeb-display-date-created-in-site-timezone.php
1 parent 3da9a52 commit 605f034

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?php
2+
/**
3+
* Gravity Perks // Entry Blocks // Display Entry's Date Created in Site Timezone
4+
* https://gravitywiz.com/documentation/gravity-forms-entry-blocks/
5+
*/
6+
add_filter( 'gpeb_entry', function( $entry) {
7+
// Convert entry's updated date to WordPress timezone and change format.
8+
$entry['date_updated'] = get_date_from_gmt( $entry['date_updated'], 'Y-m-d H:i:s' );
9+
return $entry;
10+
} );

0 commit comments

Comments
 (0)