Hey there! I'm currently working on a website that allows users to post content. I want to ensure that the site is mobile-friendly, so I need to make some adjustments with media queries.
Unfortunately, I've run into an issue where media query CSS can't change the layout of my div tags. To address this, I decided to utilize the jQuery function insertBefore.
Specifically, I'm trying to move "div three" before "div one." You can see my attempt in action here: http://jsfiddle.net/PnUTX/
$(function() {
$(".three").insertBefore(".one");
});
However, the result wasn't quite what I was looking for. I'd prefer something more like this: http://jsfiddle.net/Bvdby/
I've searched for solutions but most involve toggling show/hide using $(this), which isn't exactly what I need since I'm not targeting a specific div class, but rather all classes.
Appreciate any assistance you can offer!