Friday 15 May 2015

Wrap div after another div in jQuery - jQuery PageSlide with Bootstrap work around -


I am wrapping the fall of "nav" before "navel" and wrapping it after "pagelide"

Not sure that this is the best way to go about it, but I'm trying to get a Bootstrap submenus to play well with the PageSlide plugin.

The HTML I currently have: & lt; Div id = "pageslide" & gt; & Lt; Ul id = "nava" class = "nav sleddurn" & gt; & Lt; Li & gt; 1 & lt; / Li & gt; & Lt; Li & gt; 2 & lt; / Li & gt; & Lt; Li & gt; 3 & lt; / Li & gt; & Lt; / Ul & gt; & Lt; / Div & gt;

What do I need to get:

  & lt; Div id = "pageslide" & gt; & Lt; Div class = "nav-collapse collapse" & gt; & Lt; Ul id = "nava" class = "nav sleddurn" & gt; & Lt; Li & gt; 1 & lt; / Li & gt; & Lt; Li & gt; 2 & lt; / Li & gt; & Lt; Li & gt; 3 & lt; / Li & gt; & Lt; / Ul & gt; & Lt; / Div & gt; & Lt; / Div & gt;   

jQuery: $ ("& lt; div class = 'nav-collapse collapse' & gt;") InsertAfter ("# nav"). Attached ($ ("# pageslide"));

"text">

you can try it Are

  $ ("# pageslide"). WrapInner ("

No comments:

Post a Comment