How to format dates returned from WordPress Automatic

WordPress Automatic posts from various sources to WordPress and can return the date when the item was posted at the source. Sometimes you may want a custom format other than the returned default one

The plugin has a tag named [formated_date] which can wrap a date tag to alter it’s format

How to use the formated_date tag?

The tag can be used in two ways the first one receives a time stamp as the source time and the second one receives the date

1- spot the correct tag that return the timestamp or the date for your campaign

For example in Youtube campaigns the tag used for the timestamp is [vid_time]

2- build the custom format for the date following the rules listed here

For example my chosen custom format is d/m/Y

3- If the tag for the time returns a timestamp, Use the formatting tag as follow

[formated_date format="YOUR_FORMAT" timestamp="TAG_THAT_RETURNS_A_TIMESTAMP"]

so for our example the tag will be

[formated_date format="d/m/Y" timestamp="[vid_time]"]

Final date at the front end will be like this

4- If the tag for the time returns a date, Use this format

[formated_date format="YOUR_FORMAT" ][TAG_THAT_RETURNS_A_DATE_TIME][/formated_date]

so for example Youtube campaigns has the tag [vid_date] , the format tag will be like this

[formated_date format="d/m/Y" ][vid_date][/formated_date]

Happy formatting 😀

Leave a Reply

Your email address will not be published. Required fields are marked *