Boostrap: Filtering Results in Tabbed Content

Hi,

I’m building a site with PHP and bootstrap and trying to find a way to filter results without breaking the tabbed content.

At the moment, I have three tabs with unique ids like #tab1 #tab2 etc.

On one of the tabs, I’d like to offer the option of filtering results so would like to have a list of options to reload the tabbed content but with additional get variables so that the links would be href=#tab1?filter_id=1 but not surprisingly that is breaking the jquery.

If anyone has any ideas for how I should approach this, it would be much appreciated.

Many thanks in advance.

Hi arthurnegas,

Query string values have to go before the fragment (the #tab1 part) otherwise they won’t be sent to the server by the browser. Your href value should be ?filter_id=1#tab1

Hi Fretburner,

You’re a star. Was contemplating starting a very unwelcome plan B tomorrow. Have tested and that works a treat.