【发布时间】:2011-05-03 07:26:06
【问题描述】:
我正在使用 coda-slider 并更改 css 文件中的面板大小 trought JQuery。我这样做是为了将 coda-slider 调整为大小窗口。 这在 Firefox 中运行良好,但会使 Chrome 和 Safari 崩溃。 有谁知道我该如何解决这个问题?
这是函数
function resizeCentro() {
var alt = (document.height * 0.95) + "px";
var larg = (document.width * 0.77) + "px";
$(".coda-slider").css('width', larg);
$(".coda-slider").css('height', alt);
$(".panel-wrapper").css('width', larg);
$(".panel-wrapper").css('height', alt);
document.getElementById("ifInicio").width = document.width * 0.95;
document.getElementById("ifInicio").height = document.height * 0.95;
document.getElementById("ifInicio").src = "inicio.html";
}
【问题讨论】:
-
jQuery 在哪里?如果您使用该库,请使用它。
-
该链接重定向到根目录,其中包含大量弹出窗口,通常看起来应该避免。
标签: jquery css firefox google-chrome safari