CMS Development

FabioM
Participant

Get website Page with Hubl

SOLVE

Hi there!
I would like to know if there's a way to get a listing of website pages using a for loop with hubl and some filtering.
For example I would like to create a internal page for sales and marketing team highlighting all pages in a campaign.
Another example would a front-page for all the features of our software, filtering all URLs with /software/ in their canonical URL.

I found many ways to do so for blog pages, but I can't really find a way for website or landing pages. I also thought about using APIs, but it would be quite complex to implement a backend solution.

 

Thank you so much in advance!

1 Accepted solution
Yoshi
Solution
HubSpot Employee
HubSpot Employee

Get website Page with Hubl

SOLVE

Hey @mkthgrd

Currently, It seems not possible to print URL of all pages that are associated with a specific campaign. 

 

However, we have a feature called campaign analytics under the reporting tool. 

If the page is associated with a campaign, it should list all pages that are associated with a specific campaign. 

 

Looking at here (https://designers.hubspot.com/docs/hubl/hubl-supported-variables), we have a list of variables that can be used for pages, and it seems that we can pull URL info from that specific page, but not all URL that lives in HubSpot website tool. 

 

May I know what is the reason why you do not want to use HubDB? 

プロフェッショナルサービス


栁澤啓明|シニアテクニカルコンサルタント

View solution in original post

11 Replies 11
roisinkirby
HubSpot Product Team
HubSpot Product Team

Get website Page with Hubl

SOLVE

Hey @FabioM,

 

There are several discussion threads on the Community r.e. this topic. I'd reccommend reviewing the solutions / insights below and commenting if you have any outstanding quesitons related to your topic:

 

Blog Loop using specific post IDs

Blog pagination with loop 

 

0 Upvotes
FabioM
Participant

Get website Page with Hubl

SOLVE

Hi, ank you for your answer.

I read the  threads you linked, but these are solution for listing blog post.

I need to do something similar with Website pages or Landing Pages without using a DB.

0 Upvotes
jao28
Participant

Get website Page with Hubl

SOLVE

I am in need of the same functionality, has there been any progress made in this request?

0 Upvotes
roisinkirby
HubSpot Product Team
HubSpot Product Team

Get website Page with Hubl

SOLVE

Hello @FabioM apologies, I misread your question. Could you both please share links to your pages, links to the pages you want to list, and specific details about your goals / what you are trying to achieve. 

0 Upvotes
FabioM
Participant

Get website Page with Hubl

SOLVE

Hi @roisinkirby, thank you for your answer! My first example is this page: https://www.thron.com/it/customers/case-histories 

Here we have some website pages with a common URL structure (../customers/case-histories/..) and we want a list of all that pages.

Right now I am using a js component and I am aware a HubDB table can be used to build that list, but if something similar to hubl blog listing markup would we available, I can get the same result without the need to update manually a table.

It's not so easy to clearly focus what page data would be useful in this context: page url, canonical url, page author, campaings, page title, internal title ad meta are essential, I don't know about other informations, such as template used or publishing status.

I hope my use case is clear!

0 Upvotes
mkthgrd
Participant | Diamond Partner
Participant | Diamond Partner

Get website Page with Hubl

SOLVE

Hi @FabioM@roisinkirby@jao28!

 

Any updates on this? I'm trying to do the exactly same thing...

 

I want to create a blog listing page with blog posts and landing pages directly within the loop.

 

Is it possible?

0 Upvotes
roisinkirby
HubSpot Product Team
HubSpot Product Team

Get website Page with Hubl

SOLVE

HI @mkthgrd - this isn't my area of expertise, but CC'ing some our experts to confirm: @Yoshi, @Jsum do you know if this is possible?

0 Upvotes
Yoshi
Solution
HubSpot Employee
HubSpot Employee

Get website Page with Hubl

SOLVE

Hey @mkthgrd

Currently, It seems not possible to print URL of all pages that are associated with a specific campaign. 

 

However, we have a feature called campaign analytics under the reporting tool. 

If the page is associated with a campaign, it should list all pages that are associated with a specific campaign. 

 

Looking at here (https://designers.hubspot.com/docs/hubl/hubl-supported-variables), we have a list of variables that can be used for pages, and it seems that we can pull URL info from that specific page, but not all URL that lives in HubSpot website tool. 

 

May I know what is the reason why you do not want to use HubDB? 

プロフェッショナルサービス


栁澤啓明|シニアテクニカルコンサルタント

FabioM
Participant

Get website Page with Hubl

SOLVE

Hi Yoshi,

ok, that's pretty clear.

To use a HubDB to print pages with a loop I need to write the table first.

So my problem is: is there a way to create/update this table automatically without an external integration? For example: export a list of all pages with an API, parse the response and write all correspondant URLs in the table.

This is a viable way, but requires an external automation doing it.

Thank you

0 Upvotes
Yoshi
HubSpot Employee
HubSpot Employee

Get website Page with Hubl

SOLVE

Hey @FabioM,

At this time, the table needs to update manually and we do not have a way to update table whenever a page is created within HubSpot. 

 

@mkthgrd

HubDB can be used only on website/landing pages but not on blog pages. 

 

 

 

 

プロフェッショナルサービス


栁澤啓明|シニアテクニカルコンサルタント

0 Upvotes
mkthgrd
Participant | Diamond Partner
Participant | Diamond Partner

Get website Page with Hubl

SOLVE

Hi @Yoshi and thank you for your answer!

 

At the beginning, I could not use HubDB because it was not available in the portal we use...

 

But things are moving and we are going to subscribe to the HubSpot CMS.

 

How can I create a blog listing and insert a HubDB loop inside?

Do you have an example? A snippet?

 

Thanks!

0 Upvotes