gpt4 book ai didi

使用 Dreamweaver 时 HTML 按钮不响应 CSS

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

大家好,我的 HMTL 和分配给它的 CSS 无法正常工作时遇到问题。该按钮有效,它会正常链接,但 CSS 不会影响它。我使用 Dreamweaver CC,在设计 View 中,CSS 似乎可以正常工作,但一旦我在浏览器上实时查看它,它就会恢复到其原始状态,我将提供一些代码图片和实时 View 来向您展示我的意思。

我的 HTML

<a href="methandrailhome.html" class="returnhome">Return Home</a><!-- end .returnhome -->

我的 CSS

#form .returnhome {

-moz-box-shadow:inset -4px 2px 0px -13px #ffffff;
-webkit-box-shadow:inset -4px 2px 0px -13px #ffffff;
box-shadow:inset -4px 2px 0px -13px #ffffff;
background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #f9f9f9), color-stop(1, #e9e9e9) );
background:-moz-linear-gradient( center top, #f9f9f9 5%, #e9e9e9 100% );
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#f9f9f9', endColorstr='#e9e9e9');
background-color:#f9f9f9;
-webkit-border-top-left-radius:0px;
-moz-border-radius-topleft:0px;
border-top-left-radius:0px;
-webkit-border-top-right-radius:0px;
-moz-border-radius-topright:0px;
border-top-right-radius:0px;
-webkit-border-bottom-right-radius:0px;
-moz-border-radius-bottomright:0px;
border-bottom-right-radius:0px;
-webkit-border-bottom-left-radius:0px;
-moz-border-radius-bottomleft:0px;
border-bottom-left-radius:0px;
text-indent:-1.9px;
border:2px solid #dcdcdc;
display:inline-block;
color:#666666;
font-family:Arial;
font-size:13px;
font-weight:bold;
font-style:normal;
height:40px;
line-height:40px;
width:95px;
text-decoration:none;
text-align:center;
text-shadow:0px 0px 0px #ffffff;
}

    .returnhome {

-moz-box-shadow:inset -4px 2px 0px -13px #ffffff;
-webkit-box-shadow:inset -4px 2px 0px -13px #ffffff;
box-shadow:inset -4px 2px 0px -13px #ffffff;
background:-webkit-gradient( linear, left top, left bottom, color-stop(0.05, #f9f9f9), color-stop(1, #e9e9e9) );
background:-moz-linear-gradient( center top, #f9f9f9 5%, #e9e9e9 100% );
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#f9f9f9', endColorstr='#e9e9e9');
background-color:#f9f9f9;
-webkit-border-top-left-radius:0px;
-moz-border-radius-topleft:0px;
border-top-left-radius:0px;
-webkit-border-top-right-radius:0px;
-moz-border-radius-topright:0px;
border-top-right-radius:0px;
-webkit-border-bottom-right-radius:0px;
-moz-border-radius-bottomright:0px;
border-bottom-right-radius:0px;
-webkit-border-bottom-left-radius:0px;
-moz-border-radius-bottomleft:0px;
border-bottom-left-radius:0px;
text-indent:-1.9px;
border:2px solid #dcdcdc;
display:inline-block;
color:#666666;
font-family:Arial;
font-size:13px;
font-weight:bold;
font-style:normal;
height:40px;
line-height:40px;
width:95px;
text-decoration:none;
text-align:center;
text-shadow:0px 0px 0px #ffffff;
}
<a href="#" class="returnhome">Return Home</a>

Here is what live view from Dreamwweaver is showing

最佳答案

把那个 #form 拿出来。

.returnhome {
-moz-box-shadow: inset -4px 2px 0px -13px #ffffff;
-webkit-box-shadow: inset -4px 2px 0px -13px #ffffff;
box-shadow: inset -4px 2px 0px -13px #ffffff;
background: -webkit-gradient( linear, left top, left bottom, color-stop(0.05, #f9f9f9), color-stop(1, #e9e9e9));
background: -moz-linear-gradient( center top, #f9f9f9 5%, #e9e9e9 100%);
filter: progid: DXImageTransform.Microsoft.gradient(startColorstr='#f9f9f9', endColorstr='#e9e9e9');
background-color: #f9f9f9;
-webkit-border-top-left-radius: 0px;
-moz-border-radius-topleft: 0px;
border-top-left-radius: 0px;
-webkit-border-top-right-radius: 0px;
-moz-border-radius-topright: 0px;
border-top-right-radius: 0px;
-webkit-border-bottom-right-radius: 0px;
-moz-border-radius-bottomright: 0px;
border-bottom-right-radius: 0px;
-webkit-border-bottom-left-radius: 0px;
-moz-border-radius-bottomleft: 0px;
border-bottom-left-radius: 0px;
text-indent: -1.9px;
border: 2px solid #dcdcdc;
display: inline-block;
color: #666666;
font-family: Arial;
font-size: 13px;
font-weight: bold;
font-style: normal;
height: 40px;
line-height: 40px;
width: 95px;
text-decoration: none;
text-align: center;
text-shadow: 0px 0px 0px #ffffff;
}
<a href="methandrailhome.html" class="returnhome">Return Home</a>

关于使用 Dreamweaver 时 HTML 按钮不响应 CSS,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44420363/

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