Hello,
I'm writing a page that works with javascript scrollers that works like this:
<div id=begin scroller>
<div id=newitem> first row content </div>
<div id=newitem> 2nd row content </div>
<div id=newitem> 3rd row content </div>
</div>
Each of the 'newitem' div will be scolled up vertically one by one after a period of time. Now I need to grab some data from my database such as:
echo "<div id=begin scoller>";
while($row = mysql_fetch_array($query))
{
echo "<DIV id=newitem>";
echo $row[content];
echo "</div>";
}
wcho "</div>";
easy enough.. but what I really need is to put 4 values in one row spaced by styled SPAN (no repeat), so that it looks like:
<div id=begin scroller>
<div id=newitem>
<span>content1</span><span>content2></span><span>content3></span><span>content4</span>
</div>
<div id=newitem>
<span>content5</span><span>content6></span><span>content7></span><span>content8</span>
</div>
<div id=newitem>
<span>content9</span><span>content10></span><span>content11></span><span>content12</span>
</div>
I tried FOR LOOP but it just repeats the value before moving on to the next div...
Please HELP! Thanks.