APIs & Integrations

Not applicable

Incorrect date on blog index page

SOLVE

On my actual blogs the dates are showing up correctly, but on the blog index page the latest blogs all show up as published on June 6th. The website is hosted on WordPress but our blog is on Hubspot. Any ideas how to fix these dates: http://blog.infix.us/blog

Thanks,
CT

0 Upvotes
1 Accepted solution
Derek_Gervais
Solution
HubSpot Alumni
HubSpot Alumni

Incorrect date on blog index page

SOLVE

Hi @Christine_Trezise,

It looks like your month and day variables are being populated with the following:

{{ content.publish_date_local_time.strftime('%b') }}
{{ content.publish_date_local_time.strftime('%m') }}

Instead, you'll want to use:

{{ datetimeformat(content.publish_date_local_time, '%b') }}
{{ datetimeformat(content.publish_date_local_time, '%d') }} 

View solution in original post

0 Upvotes
2 Replies 2
Derek_Gervais
Solution
HubSpot Alumni
HubSpot Alumni

Incorrect date on blog index page

SOLVE

Hi @Christine_Trezise,

It looks like your month and day variables are being populated with the following:

{{ content.publish_date_local_time.strftime('%b') }}
{{ content.publish_date_local_time.strftime('%m') }}

Instead, you'll want to use:

{{ datetimeformat(content.publish_date_local_time, '%b') }}
{{ datetimeformat(content.publish_date_local_time, '%d') }} 
0 Upvotes
Not applicable

Incorrect date on blog index page

SOLVE

Thank you!! This fixed the problem :fireworks: