WordPress add_filter to post_date

You need to add an additional filter on the frontend. Very basically it would look like this: Frontend (eg. single.php): echo apply_filters( ‘my_custom_persian_filter’, $post_date ); Backend (eg. functions.php) function persian_date_function( $date ) { $date = $converted_to_persian; // there you convert date to persian return $date; } add_filter( ‘my_custom_persian_filter’, ‘persian_date_function’ );

How to get post creation date?

The post_date and post_date_gmt serves as the date that the post was created. For scheduled posts this will be the date on which the post is scheduled to be published. There is no reliable native method to determine the date when a scheduled post was added. For scheduled posts, you can try the post_modified or … Read more

Possible to edit custom date field and display?

Editing the theme is a good way to get this done, if it’s a theme with updates from someone else I would make a child theme to prevent your changes being overwritten: https://developer.wordpress.org/themes/advanced-topics/child-themes/ Another option is to make a plugin that utilizes a shortcode that allows any WordPress editor to just plug that shortcode into … Read more

How can get the last post date of the user?

In your sample code the $latest_posts is an instance of WP_Query class. If you want to get the latest post’s date, you should do this: $latest_posts = new WP_Query( $args ); $last_date=””; if ( $latest_posts->have_posts() ) { $latest_posts->the_post(); $last_date = get_the_date(); } return $last_date;

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)