Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/user-interface/2.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
Image 图像点击对话框?_Image_Onclick - Fatal编程技术网

Image 图像点击对话框?

Image 图像点击对话框?,image,onclick,Image,Onclick,我正在尝试获取一个图像(cookie策略),单击该图像后,会显示一个对话框,通知此网站上使用了cookie。我希望使用jQuery对话框,但似乎很难 演示链接: 我要使用的jQuery: 我为你做了一把小提琴,希望对你有所帮助 HTML: <div id="oneout"> <span class="onetitle"></span> <div id="oneout_inner"> <center>

我正在尝试获取一个图像(cookie策略),单击该图像后,会显示一个对话框,通知此网站上使用了cookie。我希望使用jQuery对话框,但似乎很难

演示链接:

我要使用的jQuery:




我为你做了一把小提琴,希望对你有所帮助

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" );
    });
});