Image 图像点击对话框?
我正在尝试获取一个图像(cookie策略),单击该图像后,会显示一个对话框,通知此网站上使用了cookie。我希望使用jQuery对话框,但似乎很难 演示链接: 我要使用的jQuery:Image 图像点击对话框?,image,onclick,Image,Onclick,我正在尝试获取一个图像(cookie策略),单击该图像后,会显示一个对话框,通知此网站上使用了cookie。我希望使用jQuery对话框,但似乎很难 演示链接: 我要使用的jQuery: 我为你做了一把小提琴,希望对你有所帮助 HTML: <div id="oneout"> <span class="onetitle"></span> <div id="oneout_inner"> <center>
我为你做了一把小提琴,希望对你有所帮助
HTML:
<div id="oneout">
<span class="onetitle"></span>
<div id="oneout_inner">
<center>
<a><img id="opener" src="https://dl.dropboxusercontent.com/u/89687987/mycookie.png" alt="cookie policy" /></a>
<br>
</center>
</div>
</div>
<div id="dialog" title="Basic dialog">
<p>This is an animated dialog which is useful for displaying information. The dialog window can be moved, resized and closed with the 'x' icon.</p>
</div>
<div id="oneout">
<span class="onetitle"></span>
<div id="oneout_inner">
<center>
<a><img id="opener" src="https://dl.dropboxusercontent.com/u/89687987/mycookie.png" alt="cookie policy" /></a>
<br>
</center>
</div>
</div>
<div id="dialog" title="Basic dialog">
<p>This is an animated dialog which is useful for displaying information. The dialog window can be moved, resized and closed with the 'x' icon.</p>
</div>
$(function() {
$( "#dialog" ).dialog({
autoOpen: false,
show: {
effect: "blind",
duration: 1000
},
hide: {
effect: "explode",
duration: 1000
}
});
$( "#opener" ).click(function() {
$( "#dialog" ).dialog( "open" );
});
});