Javascript 如何使用编辑元素!重要的
这是我的密码:Javascript 如何使用编辑元素!重要的,javascript,weebly,Javascript,Weebly,这是我的密码: <body class="no-header-page wsite-page-index full-width-body-off header-overlay-on alt-nav-off wsite-theme-light fade-in" style="min-height: 100%; position: relative; height: auto !important; padding-bottom: 64px !important;"> 我想使
<body class="no-header-page wsite-page-index full-width-body-off header-overlay-on alt-nav-off wsite-theme-light fade-in" style="min-height: 100%; position: relative; height: auto !important; padding-bottom: 64px !important;">
我想使用javascript或其他方法将“padding bottom:64px!important;”更改为“padding bottom:0px!important;”
谢谢大家! 就在
主体
标签添加关闭之前
<script>
document.getElementsByTagName('body')[0].style.setProperty("padding-bottom", "0px", "important");
</script>
document.getElementsByTagName('body')[0].style.setProperty(“填充底部”、“0px”、“重要”);
谢谢您的回答!然而,我试过了,但没有成功。这是我的网站:austin0910.weebly.com谢谢!因为您已经在页面中包含了jQuery,为了使它更容易,请改为包含$('body').css('paddingBottom','0')
the!重要信息
是不必要的,因为您正在内联样式,并且在其他地方没有可以覆盖该样式的声明。