• Resolved dunc_sf

    (@dunc_sf)


    Good afternoon. Awesome plugin, works superly for me.

    I’m currently using the [post_date] shortcode in some of my notifications.

    Is there a way of making this prettier? Something like [post_date='F d,Y']?

    Thanks in advance.
    Duncan

    • This topic was modified 7 years, 7 months ago by dunc_sf.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author bnfw

    (@voltronik)

    Hi @dunc_sf,
    Thanks for your message.

    I think the default output from this should be taking your settings from WordPress > Settings.
    Can you confirm if this is correct?

    Thanks,
    Jack

    Thread Starter dunc_sf

    (@dunc_sf)

    Thanks for the quick reply.

    No, it seems not to.

    It outputs as 2017-08-09 17:35:22 where my WordPress settings as they are at the monet should output 9th August 2017, 2:07pm.

    I’ve just noticed I’m actually using [post_date_gmt]. What’s the difference between the two codes? Should I just be using [post_date]?

    Plugin Author bnfw

    (@voltronik)

    Hi @dunc_sf,
    In that case, i’ll investigate and see if I can change this in a future version.

    [post_date_gmt] is exactly the same as [post_date] except it outputs in the GMT timezone instead.

    Thanks,
    Jack

    Thread Starter dunc_sf

    (@dunc_sf)

    Thanks Jack, that would be great. Ideally, just some PHP-esque formatting would be ideal, as per my original post.

    Thread Starter dunc_sf

    (@dunc_sf)

    Ah, you’ve done it already!! You legend ?? That’s phenomenal support.

    For anyone visiting this thread in future, you can now use [current_date] and [current_time] which will display in the way that you’ve set WordPress to display dates and times (Settings -> General).

    Plugin Author bnfw

    (@voltronik)

    Hi @dunc_sf,

    You can use those but it will show the current date and time of the email as opposed to the date and time that the post was published.

    Just wanted to clarify that but hope the new shortcodes help!

    Thanks,
    Jack

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Nicer date/time shortcode’ is closed to new replies.