grab from all blog post pages hubL

SOLVE
zman5664
Participant

Right now we have three differnt blog pages we are using a RSS to retrive the most recent blog post but it only displays for the that current page. Is there a way we can get recent blog post from all blog pages in one RSS?

 

This is are current setup

 

{% if module.rss_feed_type == "external" %}
    {% set feed_source = "{is_external=True, rss_url='"~module.rss_url~"', state='PUBLISHED}" %}
    {% set is_external = true %}
{% elif module.rss_feed_type == "blog" %}
    {% set feed_source = "{is_external=false, , order_by=-publish_date, state='" ~  module.choice_field ~ "', rss_url='' }" %}
    {% set is_external = false %}
{% endif %}

<div>
{% rss_listing
    publish_date_text="{{ module.publish_date_text }}",
    rss_url="{{ module.rss_url }}",
    is_external="{{ is_external }}",
    click_through_text="{{ module.click_through_text }}",
    show_date="{{ module.show_date }}",
    include_featured_image="{{ module.include_featured_image }}",
    publish_date_format="{{ module.publish_date_format }}",
    show_detail="{{ module.show_detail }}",
    show_author="{{ module.show_author }}",
    number_of_items="{{ module.number_of_items }}",
    title="{{ module.title }}",
    limit_to_chars="{{ module.limit_to_chars }}",
    attribution_text="{{ module.attribution_text }}",
    topic_id="{{ module.topic_id }}"
    feed_source="{{ feed_source }}"
%}
</div>
0 Upvotes
1 Accepted solution

Accepted Solutions
Derek_Gervais
Solution
HubSpot Employee

Hey @zman5664 ,

 

Just to clarify, are you trying to pull multiple RSS feeds into a single page? That's not possible with a single RSS module, but it is possible if you include multiple RSS modules.

 

Also side note: While I'm not 100% sure, based on the conditional logic you included it seems like you might also be using the RSS module to pull HubSpot blogs? That techncially works, but you might find it more effective to use our built-in HubL blog functions described here: https://designers.hubspot.com/en/docs/hubl/hubl-supported-functions

View solution in original post

1 Reply 1
Derek_Gervais
Solution
HubSpot Employee

Hey @zman5664 ,

 

Just to clarify, are you trying to pull multiple RSS feeds into a single page? That's not possible with a single RSS module, but it is possible if you include multiple RSS modules.

 

Also side note: While I'm not 100% sure, based on the conditional logic you included it seems like you might also be using the RSS module to pull HubSpot blogs? That techncially works, but you might find it more effective to use our built-in HubL blog functions described here: https://designers.hubspot.com/en/docs/hubl/hubl-supported-functions

View solution in original post