gpt4 book ai didi

javascript - CSS 如何设置宽度?

转载 作者:行者123 更新时间:2023-11-28 03:07:09 25 4
gpt4 key购买 nike

我继承了一个有幻灯片放映的网页,但我不知道如何更改 <article> 的宽度包含幻灯片放映。我认为它正在通过 JavaScript 变大,但我已经搜索过但无法弄清楚在哪里。

如果您在页面上查看源代码,您不会在文章标签中看到宽度,但如果您使用 firebug 查看样式,您会看到:

element.style {
width: 565px;
}

我在这里发布了一个示例版本:http://208.112.58.198/help/index_new.htm .

最佳答案

jquery plugin 正在应用您元素的 CSS 宽度.

/help/wp-content/themes/Cobalt3/cobalt/js/main68b3.js 此文件第 339 行具有以下代码。

$('#part-slideshow').carouFredSel({
height: 300,
width: '100%',
circular: true,
items: {
visible: 1,
height: 300,
},
scroll: {
items: 1,
fx: "crossfade",
duration: 1000,
easing: "swing"
},
auto: {
timeoutDuration: 5000,
delay: 5000,
pauseOnHover: true
},
pagination: '#pagination',
swipe: {
onTouch: true,
onMouse: true
},
responsive: true
});

该插件将一个 resize 事件函数绑定(bind)到轮播元素,它根据屏幕尺寸设置元素宽度,因为在调用中添加了 responsive: true 选项。

关于javascript - CSS 如何设置宽度?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32109532/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com