jQuery代码:如何垂直居中jQuery Modal?
function thumb(id,ths) {
if (<?=$loggedin?>) {
$.post(base_url+"index.php/myad/addthumbs", {uniqueid:id});
$(ths).addClass("red");
} else {
_ths=$(ths);
var number = Math.floor(Math.random()*90000) + 10000;
$("#captcha").attr("data-id",id);
$("#captcha").text(number);
$("#pop").modal("show");
}
}
我如何中心模式?请帮助我,并提前致谢。
我在google和stackoverflow上找到了解决方案,但是当它由纯jquery构建时,问题是基于bootstrap的模态。
请参阅此链接:https://codepen.io/dimbslmh/full/mKfCc – Vijai