View Single Post
Old 10-08-2012, 09:04 PM   PM User | #4
xelawho
Senior Coder

 
xelawho's Avatar
 
Join Date: Nov 2010
Posts: 2,437
Thanks: 52
Thanked 454 Times in 452 Posts
xelawho will become famous soon enoughxelawho will become famous soon enough
actually more like this, strictly following the required outcome...

Code:
<script>
$($('div[class*=" x"]').not($('div[class*=" x"]:last')).get().reverse()).each(function() {
$(this).attr("class","changed")
$('div[class*=" x"]:last').prepend($(this));
});
</script>
xelawho is offline   Reply With Quote
Users who have thanked xelawho for this post:
johnsmith153 (10-08-2012)