• Resolved Sampression

    (@sampression)


    Here’s a small tip for implementing radio button behaviour on “Sampression Lite” theme.
    Go to script.js on \wp-content\themes\sampression-lite\lib\js and add a line after line 121.

    jQuery('.nav-listing li a').removeClass('selected');
    /*-    This did it!(radio button like)!           */

    All credit goes to John A. Grindle

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Sampression

    (@sampression)

    Here’s a small tip for implementing radio button behaviour on “Sampression Lite” theme.
    Go to script.js on \wp-content\themes\sampression-lite\lib\js and add a line after line 121.

    jQuery('.nav-listing li a').removeClass('selected');
    /*-    This did it!(radio button like)!           */

    All credit goes to John A. Grindle

    Hi, Thank you for a great theme. Getting the navigation to work like radio buttons is exactly what I was looking to modify, however this bit of code doesn’t seem to change anything for me. Do I have it in the correct place? Are there any other parts of the code I need to modify? Thanks in advance.

    if(elm.children('ul').length>0){
    
     jQuery('.nav-listing li a').removeClass('selected');
    /*-    This did it!(radio button like)!           */
    
    parentelem.after(jQuery("<option />", {
        "class" : "level-menu-"+level,
        "value"   : anchor.attr("href"),
        "text"    : dash+anchor.text()
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to achieve radio button behaviour’ is closed to new replies.