EcoWeb -Website design Services

Fetch HubDb Data into HubSpot Modules

Hubspot
hubdb
First step is to Grab the id from the Hubdb table.   Id which we are going to use is 5252243

<!-- variable contains all unfiltered table data -->
{% set data = hubdb_table_rows(5252243) %}


<!-- Loop through each row  -->
{% for row in data %}
  <!--Print your each row -->
  {{row|pprint}}
  
{% endfor %}
Each row returns an object. So you can easily access any field data with dot notation.

<!-- variable contains all unfiltered table data -->
{% set hubdbdata = hubdb_table_rows(5244337) %}


<!-- Loop through each row  -->
{% for row in hubdbdata %}
  <article class="basic-card">
    <img src="{{row.image.url}}" alt"{{row.name}}"/>
    <h3 class="name">{{row.name}}</h3>
    <span class="category">{{row.category}}</span>
  </article>
{% endfor %}
if you want to make your Hubdb  table id option more user-friendly means giving the  ability to use to change your  Hubdb  table from page editor then: HubDb   Select Hubdb Option and replace and copy its value and replace hubdb id with its value eg: 5252243 with module.hubdbtable_field  

<!-- variable contains all unfiltered table data -->
{% set hubdbdata = hubdb_table_rows(module.hubdbtable_field) %}


<!-- Loop through each row  -->
{% for row in hubdbdata %}
  <article class="basic-card">
    <img src="{{row.image.url}}" alt"{{row.name}}"/>
    <h3 class="name">{{row.name}}</h3>
    <span class="category">{{row.category}}</span>
  </article>
{% endfor %}
Roger now you can select any table from list to fetch select table

Socialize Your Business Using Social Media Marketing

Consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi
- Adam Johnson
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation
emails-list-on-a-laptop-screen-office-background.jpg
Consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum
Tag Post :
Share This :