• Hi,
    I am looking to add a selection table element that can be found on the demo theme page i have seen and put above. It is the Entrepreneur Meets Marketer section where you can select the section on the left and it shows different option.

    Thanks

    • This topic was modified 2 years, 4 months ago by Jan Dembowski. Reason: Moved to Fixing WordPress, this is not an Developing with WordPress topic

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator bcworkz

    (@bcworkz)

    Are you looking for a plugin that lets you do something like that, or do you wish to develop your own solution and just need to be pointed in the right direction? This is the Developing WordPress forum after all.

    If you look at the source HTML and CSS of the page, you should see all the different contents are all part of the page. Their CSS styling causes each one to occupy the same position on the page. All but one is assigned a class that has a display: none; CSS property associated with it, so all but one are invisible.

    When one clicks on the various options, a bit of JavaScript listening for a click event will remove the class from the chosen content, making it visible. It’ll also assign the class to all the other contents to ensure they are all invisible.

    It’s the same mechanism used for tabbed pages, except it is only applied to a particular section and the “tabs” (the options) are not styled to look like literal tabs. If you do some searching, there are all sorts of tutorials on creating tabbed pages.

    Thread Starter lukelaj

    (@lukelaj)

    Hi,

    Thanks for the reply. Was looking at either plugin or a steer in the right direction for code.

    The code side is a little bit new to me and still learning that side so picking bits up.

    Thanks

    Moderator bcworkz

    (@bcworkz)

    A plugin search for “tabbed pages” doesn’t yield much that looks promising. Still, looking at the tabbed page source HTML and CSS from the few plugins that actually do tabbed pages might help in further understanding. But I think the generic tutorials you can find through a general internet search would be more helpful. It’s just that you’d apply the concept to a specific section instead of the entire page.

    The only problem with generic tutorials is you’d need to adapt the code suggestions to accommodate some WordPress quirks. Mainly that external JS and CSS file references are not placed directly in HTML content. They are instead enqueued through PHP code. In the end the results are the same.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Filterable Table’ is closed to new replies.