gpt4 book ai didi

jquery添加宽度+填充;

转载 作者:行者123 更新时间:2023-12-03 22:47:52 27 4
gpt4 key购买 nike

我正在尝试做 var width = ($(this).width() + $(this).css('padding-left') + $(this).css('padding-right' ));

将宽度添加到填充中,所以我最终应该得到 width = 200 + 4 + 4 = 208相反,我最终得到 2004px4px;

我怎样才能强制它添加它们以获得208?

最佳答案

为什么不使用outerWidth属性呢? http://api.jquery.com/outerWidth/

关于jquery添加宽度+填充;,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3544503/

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