HubDB Question

SOLVE
Highlighted
New Contributor

Hello Developer community! I recently set up a HubDB to easily display customer testimonials.  The page was intended to show rows 1-3 and the remainding ones in a hidden div (like a show/hide jquery thing). I toyed with writing a query to manually display the row I want, but that could get pretty cumbersome considering we have 10 rows now and are expecting to add more.  Is there a more efficient way to do this? I'd imagine I can change the query in the module, but I'm not entirely sure how to do this. Any answers will be very much appreciated! Thanks in advance! 

Reply
0 Upvotes
1 Accepted solution

Accepted Solutions
Advisor

@pixelilly you would need to add a limit parameter to your query. You can do this in HubL like so:

{% set table = hubdb_table_rows(123456,'&limit=3') %}

 Hope that helps!

--
Stefen Phelps
Web Developer / Co-founder
Kelp Creative Agency
Twitter — @stefen
1 Reply 1
Advisor

@pixelilly you would need to add a limit parameter to your query. You can do this in HubL like so:

{% set table = hubdb_table_rows(123456,'&limit=3') %}

 Hope that helps!

--
Stefen Phelps
Web Developer / Co-founder
Kelp Creative Agency
Twitter — @stefen