Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/32.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 如何在index.js拖放脚本中添加彼此相邻的图像?_Javascript_Css - Fatal编程技术网

Javascript 如何在index.js拖放脚本中添加彼此相邻的图像?

Javascript 如何在index.js拖放脚本中添加彼此相邻的图像?,javascript,css,Javascript,Css,我用的是年龄验证器 以下是我从屏幕顶部滑下的内容: $(document).ready(function() { $.age_verifier_id = "28915"; $.age_verifier_ajax_url = "http://selectoil.com/wp-admin/admin-ajax.php"; $.AgeVerifier({ enabled: "1", mode: "age", minimum_age

我用的是年龄验证器

以下是我从屏幕顶部滑下的内容:

$(document).ready(function() {
    $.age_verifier_id = "28915";
    $.age_verifier_ajax_url = "http://selectoil.com/wp-admin/admin-ajax.php";
    $.AgeVerifier({
        enabled: "1",
        mode: "age",
        minimum_age: "21",
        cookie_expiration: "365",
        animation: "slide",
        title: "Welcome to My website",
        text: "Please use the slider to verify your age",
        background: "#333",
        background_type: "color",
        background_image_url: "http://selectoil.com/wp-content/uploads/2017/06/icon-logo.png",
        text_color: "#ffffff",
        submit_text: "Enter",
        error_message: "You need to be at least [age] years old to continue.",
        safe_url: "",
        safe_url_enabled: "0"
    });
});

我尝试制作两张200px x 200px的图像,每张图像在“欢迎访问我的网站”文本上方并排向下滑动,并按照相同的幻灯片顺序向下滑动。我建议使用外部动画库。 有一个只使用CSS的库,名为 然后,您可以实现如下要求:

$('btn')。在('click',(e)=>{
$(“#覆盖”).fadeOut();
});
html,正文{
保证金:0;
填充:0;
}
#覆盖层{
背景色:#1AB4A1;
身高:100%;
保证金:0;
位置:固定;
宽度:100%;
}
#welcomeContainer{
填充:20px 0px 0px 0px;
文本对齐:居中;
}
#欢迎光临{
高度:200px;
宽度:200px;
}
#btn{
背景色:红色;
边界半径:5px;
填充:8px;
}


内容背后
Ok,但这会添加到已经发生的动画中吗?因为我需要它们都向下滑动,并且可以在与年龄文本相同的覆盖中查看,所以当输入年龄时,我需要徽标消失,就像年龄验证窗口覆盖的其余部分一样。我已经更新了答案,以符合您的扩展要求