<div id="demo" class="marquee">
<div id="demo1">
<?php if($marquee_class=="pic"){?>
<?php foreach($curr_marquee as $marquee){?>
<img src="<?php echo $marquee->pic?>" border=0 width="160" height="120"  name="picautozoom" >
<?php }?>
<?php } else {?>
<?php foreach($curr_marquee as $marquee){
// 21/09/2010
if (!empty($marquee->pic)) {
	$uri = Html::uriquery('mod_product', 'view', array('p_id' => $marquee->link));
} else {
	$uri = Html::uriquery('mod_article', 'article_content', array('article_id' => $marquee->link));
}	
?>
<p><a href="<?php echo $uri; ?>" title="<?php echo $marquee->title; ?>"><?php echo $marquee->title;?></a></p>
<?php }?>
<?php }?>

</div>
<div id="demo2"></div>
</div>
<div class="list_bot"></div>
<script>
<!--
var speed=<?php echo $marquee_speed;?>;
var tab=document.getElementById("demo");
var tab1=document.getElementById("demo1");
var tab2=document.getElementById("demo2");
tab2.innerHTML=tab1.innerHTML;
tab.scrollTop=tab.scrollHeight
function Marquee(){
if(tab1.offsetTop-tab.scrollTop>=0)
tab.scrollTop+=tab2.offsetHeight;
else{
tab.scrollTop--
}
}
var MyMar=setInterval(Marquee,speed);
tab.onmouseover=function() {clearInterval(MyMar)};//鼠标移上时清除定时器达到滚动停止的目的
tab.onmouseout=function() {MyMar=setInterval(Marquee,speed)};//鼠标移开时重设定时器
-->
</script>
