Take data from one div and insert into another section of page
What would be the best solution to this ... I want to take the 3rd content
div's image filename, link, and text), and duplicate it as the first entry
in the old section. Basically duplicating the data contents, but using the
div structure from the old section. The differences in structure as you
can see are the image file name (one using featured, and the other being
boxart), and the imgframenew and posterimage div.
If you need me to clarify let me know as this is a little abstract, and
difficult for me to describe easily in writing.
<div class="new">
<div class="content"><div class="imgframenew">
<div class="posterimage"
style="background:url(/media/images/featured/pic1.jpg);"></div></div>
<div class="title"><a rel="/media/link1/">Example 1</a></div></div>
<div class="content"><div class="imgframenew">
<div class="posterimage"
style="background:url(/media/images/featured/pic2.jpg);"></div></div>
<div class="title"><a rel="/media/link2/">Example 2</a></div></div>
<div class="content"><div class="imgframenew">
<div class="posterimage"
style="background:url(/media/images/featured/pic3.jpg);"></div></div>
<div class="title"><a rel="/media/link3/">Example 3</a></div></div>
</div><div class="old">
<!-- Duplicate 3rd div content from above, here, but using the div
structure from below -->
<div class="content"><div class="imgframe"
style="background:url(/media/images/boxart/pic1.jpg);"></div>
<div class="title"><a rel="/media/link1">Example 1</a></div></div>
<div class="content"><div class="imgframe"
style="background:url(/media/images/boxart/pic2.jpg);"></div>
<div class="title"><a rel="/media/link2">Example 2</a></div></div>
<div class="content"><div class="imgframe"
style="background:url(/media/images/boxart/pic3.jpg);"></div>
<div class="title"><a rel="/media/link3">Example 3</a></div></div>
No comments:
Post a Comment