<div id="one">test test</div>
<div id="two">test test</div>
<div id="three">test test</div>
<div id="four">test test</div>
<div id="five">test test</div>
If I want to insert a div dynamically with jQuery in between divs “four” and “five”, how would I go about doing that?
I tried this but it didn’t work:
$("<div id='four-point-five'></div>").before("#five");
It is the other way around: