Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/441.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 大屏幕停止加载_Javascript_Html_Marquee - Fatal编程技术网

Javascript 大屏幕停止加载

Javascript 大屏幕停止加载,javascript,html,marquee,Javascript,Html,Marquee,这是一个愚蠢的问题,但我已经尝试过使用和不使用javascript,而且我似乎无法在默认情况下阻止字幕 基本上,我希望它们在mousover上开始移动,但默认情况下会停止 我试过这样的东西: $.each($('.tracks_marquee'),function(){$(this).stop();}); //triggered on $.ready <marquee class="tracks_marquee" behavior="alternate" scrolldelay="160

这是一个愚蠢的问题,但我已经尝试过使用和不使用javascript,而且我似乎无法在默认情况下阻止字幕

基本上,我希望它们在mousover上开始移动,但默认情况下会停止

我试过这样的东西:

$.each($('.tracks_marquee'),function(){$(this).stop();}); //triggered on $.ready

<marquee class="tracks_marquee"
behavior="alternate"
scrolldelay="160"
onmouseover="this.start();"
onmouseout="this.stop();"
onload="this.stop();">
  some text here
</marquee>
$.each($('.tracks_marquee'),function(){$(this.stop();})//已在$.ready上触发
这里有一些文字
但是什么都不管用

试试这个

<marquee class="tracks_marquee" behavior="alternate" scrollamount="0"  >
  some text here
</marquee>



   $(document).ready(function()
{
$(".tracks_marquee").hover
  (
    function()
    {
       $(this).attr("scrollamount","1");
       $(this).start();  
    },
    function()
    {
       $(this).attr("scrollamount","0");
       $(this).stop();
    }
  )
})

这里有一些文字
$(文档).ready(函数()
{
$(“.tracks\u marquee”)。悬停
(
函数()
{
$(此).attr(“滚动金额”,“1”);
$(this.start();
},
函数()
{
$(此).attr(“滚动金额”,“0”);
$(this.stop();
}
)
})
检查一下这个现场小提琴


尝试从
中删除
$()
??老派!前两行,我知道,但是使用javascript插件,标签被div取代,并通过js效果进行管理。让我感到不安的是,不要像那样阻止他们…@Joseph有没有美元都一样,我用美元(这个)是因为我用的是美元jquery@Piero:如果您使用某种javascript模块来处理字幕,那么您可能应该说出它是哪一个。另外,
$(此)
不同。前者是一个dom元素,而第二个是一个jQuery对象,因此它们具有不同的方法和属性。