Forums

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

Home Forums CSS Insert a checkbox in a slide side menu

  • This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #198038
    rossig7
    Participant

    Hi everyone! I have the following menu, http://jsfiddle.net/s1fpz40c/4/ I want that one of the submenus has items that are checkbox buttons.
    I can’t get it working: it doesn’t respect the properties I set to them such background color, size, etc and everytime I click on it, the menu slides and the checkbox doesn’t get checked.

    I appreciate any suggestions. Thanks a lot.

    #198039
    Shikkediel
    Participant

    I don’t see any input checkboxes… but if you were to add them, make sure the jQuery is written in such a way that when the menu is clicked the checkbox itself is excluded. This could be achieved by referencing e.target (the origin of what element triggers an event).

    http://api.jquery.com/event.target/

    #198041
    Paulie_D
    Member

    Not sure what you are asking but the toggle is hidden a little in JSfiddle by the “Results” thingy in the tp corner.

    http://jsfiddle.net/s1fpz40c/7/

    #198042
    Shikkediel
    Participant

    Indeed the position of the hamburger icon wasn’t very convenient, noticed that as well and thought at first that had to do with the issue (probably should have mentioned it as well). But soon realised it’s just an arbitrary coincidence (two words that could well be a pleonasm).

    #198080
    rossig7
    Participant

    Yes, the check box wasn’t included in that example.
    My question was how to add it taking as a base that example.

    I tryed something like this:
    http://codepen.io/rossig7/pen/raqgxO

    #198081
    rossig7
    Participant

    Well, that’s an example…I am getting closer
    http://jsfiddle.net/nvzfh8ek/

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