<marquee>问题?
想在用 <marquee> 来控制些文字的上下移动,在起初加载页面的时候,是静止显示的,等鼠标移到向上或者向下后,才进行相应移动?用 <marquee> 怎么样控制?或者用JS控制也行!谢谢!
------解决方案-------------------- <marquee> 可能已经要被淘汰了
给你推荐一个
<html>
<head>
<meta http-equiv= "Content-Type " content= "text/html; charset=gb2312 ">
<title> vip </title>
</head>
<body>
<table width= "378 " border= "0 " align= "center " cellpadding= "0 " cellspacing= "0 ">
<tr>
<td width= "378 " height= "105 ">
<div id= "icefable1C ">
<div id= "box1leftC ">
<table width= "365 " border= "0 " align= "center " cellpadding= "0 " cellspacing= "0 ">
<tr>
<td width= "237 " height= "20 ">
</td>
<td width= "126 " height= "20> </td>
</tr>
<tr> <td colspan= "2 "> 还没有信息! </td> </tr>
</table> </div>
</div> </td>
</tr>
<tr> <td align= "center "> </td> </tr>
</table>
<!--//
滚动代码
//-->
<script language= "JavaScript " type= "text/javascript ">
<!--
try{
var marqueesHeightC = 100;
var stopscrollC = false;
var scrollElemC = document.getElementById( "icefable1C ");
with(scrollElemC){
style.width = 370;
style.height = marqueesHeightC;
style.overflow = 'hidden ';
noWrap = true;
}
scrollElemC.onmouseover = new Function( 'stopscrollC = true ');
scrollElemC.onmouseout = new Function( 'stopscrollC = false ');
var preTopC = 0;
var currentTopC = 0;
var stoptimeC = 0;
var leftElemC = document.getElementById( "box1leftC ");
scrollElemC.appendChild(leftElemC.cloneNode(true));
init_srolltextC();
}catch(e) {}
function init_srolltextC(){
scrollElemC.scrollTop = 0;
setInterval( 'scrollUpC() ', 20);
}
function scrollUpC(){
if(stopscrollC) return;
currentTopC += 1;
if(currentTopC == 101) {
stoptimeC += 1;
currentTopC -= 1;
if(stoptimeC == 120) {
currentTopC = 0;
stoptimeC = 0;
}
}else{
preTopC = scrollElemC.scrollTop;
scrollElemC.scrollTop += 1;
if(preTopC == scrollElemC.scrollTop){
scrollElemC.scrollTop = 0;
scrollElemC.scrollTop += 1;
}
}
}
//-->
</script>
</body>
</html>
或者你到阿里巴巴中文网站上看看他怎么弄得