Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Need help modifying a CSS/JavaScript combo

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #153075
    owlinargyle
    Participant

    I am not a JavaScript wiz, but I’m fairly adept at modifying CSS. I found a CSS/JavaScript combination at http://www.menucool.com/tabbed-content that I’d like to use. However, for the project I’m working on, I need to put another set of tabs into one of the tabs of the first tab set. I’ve basically got the CSS part worked out, but it won’t work properly because I need two separate functions for the two separate tab sets.

    So I need to duplicate the “tabs” function and just give it a new name in the JS. But I’m not sure what parts of the function I need to copy to duplicate it. My attempts have not worked right so far.

    Can someone take a quick look at my Codepen, please?

    #153163
    owlinargyle
    Participant

    I did expand the JS in my Pen, so it should be more readable there than on the original site. But I didn’t include my HTML and the CSS mods, because the JS was all I needed looked at.

    I’ve added both of those to the Pen now. I hope that gives you a better picture of what I’m trying to do.

    When you click to the third tab to the right, you’ll see my second tab set added. But those tabs won’t switch to their Divs, because they don’t have a function named “tabs2” yet. I was thinking they’d have to have their own function, because they have their own styles. Maybe I’m wrong there. Like I said, I’m not a JS wiz. =)

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.