marquee标签不支持谷歌浏览器中的悬停效果

时间:2016-03-30 08:36:02

标签: javascript jquery html css google-chrome

我使用了marquee标签。这个悬停效果标签在Mozilla中运行良好,但在谷歌浏览器中没有工作悬停效果。我试过这个解决方案。



<marquee direction="up" height="250px" onmouseover="javascript:this.setAttribute('scrollamount', 0, 0);" onmouseout="this.setAttribute('scrollamount', 6, 0);">
  
  text
  </marquee>
&#13;
&#13;
&#13;

请建议任何其他解决方案。

2 个答案:

答案 0 :(得分:0)

使用此代替它:

<marquee direction="up" height="250px" onmouseover="this.stop();" onmouseout="this.start();">
  
  text
  </marquee>

&#13;
&#13;
JNIEXPORT jlong JNICALL reader_BridgeNativeModel_nativeCreateObject
(JNIEnv *jenv, jclass, jstring jFileName){

const char* jnamestr = jenv->GetStringUTFChars(jFileName, NULL);
string stdFileName(jnamestr);
Ptr<ml::ANN_MLP> model = Algorithm::load<ml::ANN_MLP>(stdFileName)
jlong result = 0;
memcpy(&result, model, 1);            // the size seems doesn't work, tried 4, 8, but got the same result as below outputs
LOGD("model  address :%p\t", &model);
LOGD("result address :%p\t", &result);
....
}

// the output of log always like this
model  address :0xbeed51e8
result address :0xbeed51e0  
&#13;
&#13;
&#13;

答案 1 :(得分:0)

如果有人遇到同样的问题,请使用此解决方案,

&#13;
&#13;
<marquee behavior="scroll" direction="up" onMouseOver="this.setAttribute('scrollamount', 0, 0);this.stop();" OnMouseOut="this.setAttribute('scrollamount', 2, 0);this.start();" scrollamount="2"> hellow world </marquee>
&#13;
&#13;
&#13;