CMS Development

Konclude
Miembro

Get today's date to use in recent blog posts

resolver

I'd like to get today's day to use when displaying related psots: 

 

{% related_blog_posts start_date="2021-02-08", end_date="2018-06-10", limit=10 callback="blog_post_formatter" %}

 

I'd like to dynamically generate the start date. Is that possible in HUBL?

0 Me gusta
1 Soluciones aceptada
piersg
Solución
Asesor destacado

Get today's date to use in recent blog posts

resolver

Wouldn't using blog_recent_tag_posts be the same thing? Get related posts (by tag), sorted by most recent first (i.e. today).

 

 

Ver la solución en mensaje original publicado

3 Respuestas 3
Konclude
Miembro

Get today's date to use in recent blog posts

resolver

Thank you guys for everything. I appreciate your assistance. All is sorted now.

dennisedson
Equipo de producto de HubSpot
Equipo de producto de HubSpot

Get today's date to use in recent blog posts

resolver

Hi @Konclude those parameters are not available in that function. 

Am I understanding this correctly.  You want to loop through only a particular period of time and always have the most recent be the current day.

@piersg , @alyssamwilie what do you think?

0 Me gusta
piersg
Solución
Asesor destacado

Get today's date to use in recent blog posts

resolver

Wouldn't using blog_recent_tag_posts be the same thing? Get related posts (by tag), sorted by most recent first (i.e. today).