jquery图像悬停在平板电脑上
我正试图在平板电脑上使用的网站上加入一个悬停图像旋转功能。不幸的是,我对如何解决拼图的最后部分有点迷茫。有人能帮忙吗?下面的脚本在悬停时旋转图像,并添加额外的文本框jquery图像悬停在平板电脑上,jquery,mouseover,Jquery,Mouseover,我正试图在平板电脑上使用的网站上加入一个悬停图像旋转功能。不幸的是,我对如何解决拼图的最后部分有点迷茫。有人能帮忙吗?下面的脚本在悬停时旋转图像,并添加额外的文本框 jquery: $(document).ready(function(){ $(".1").hover( function(){$("#Information-Seawater").show();}, function(){$("#Information-Seawater").hide()}); }); jQuery(fun
jquery:
$(document).ready(function(){
$(".1").hover(
function(){$("#Information-Seawater").show();},
function(){$("#Information-Seawater").hide()});
});
jQuery(function(){
$(".1").hover(
function(){this.src = this.src.replace("-Icon","-Image");},
function(){this.src = this.src.replace("-Image","-Icon");
});
});
风格:
#Information-Seawater {
display: none;
top: 650px;
margin-left:auto;
margin-right:auto;
width:60%;
font-family: Consolas;
background: #00bbe4;
border: 2px solid black;
COLOR: #006080;
}
html:
`
文本
文本
上面的脚本在pc上运行良好,但在平板电脑上不起作用。我希望有人能帮助我将上面的功能与下面的功能结合起来,在平板电脑上,在开始悬停之前需要单击一次图像
或
感谢您的帮助 您不能将鼠标悬停在平板电脑上,因为只有在您触摸屏幕并点击屏幕时才会发生任何事件。尝试检测它何时是平板电脑,并绑定单击事件而不是悬停
<td class="style6" style="height: 77px; width: 140px"><a href="Http://"><img `id="1" height="147" src="website-%20images/Seawater-Icon.jpg" alt="" class="1" width="140"></a></td>`
<div id="Information-Seawater">
<span class="Information-Header">text<br /></span>
text
<br />
</div>