를 제어하는 방법 :더 나은 파이어 폭스와 구글 크롬 간격에게 CSS
body {
background:black;
width:960px;
}
#jsddm a {
padding:5px 10px;
font:16px Calibri;
text-transform: uppercase;
text-decoration: none;
font-weight:bold;
border: 2px silver outset;
color: #000000;
text-shadow:-1px 0 #AAD036, 0 1px #AAD036, 1px 0 #AAD036, 0 -1px #AAD036;
}
#one a {
background:-webkit-linear-gradient(#FF0000, white 20%, #FF0000 80%);
background:-moz-linear-gradient(#FF0000, white 20%, #FF0000 80%);
background:linear-gradient(#FF0000, white 20%, #FF0000 80%);
}
#two a {
background:-webkit-linear-gradient(#FF00FF, white 20%, #FF00FF 80%);
background:-moz-linear-gradient(#FF00FF, white 20%, #FF00FF 80%);
background:linear-gradient(#FF00FF, white 20%, #FF00FF 80%);
}
#three a {
background:-webkit-linear-gradient(#00FFFF, white 20%, #00FFFF 80%);
background:-moz-linear-gradient(#00FFFF, white 20%, #00FFFF 80%);
background:linear-gradient(#00FFFF, white 20%, #00FFFF 80%);
}
#four a {
background:-webkit-linear-gradient(#00FF00, white 20%, #00FF00 80%);
background:-moz-linear-gradient(#00FF00, white 20%, #00FF00 80%);
background:linear-gradient(#00FF00, white 20%, #00FF00 80%);
}
#five a {
background:-webkit-linear-gradient(#FFFF00, white 20%, #FFFF00 80%);
background:-moz-linear-gradient(#FFFF00, white 20%, #FFFF00 80%);
background:linear-gradient(#FFFF00, white 20%, #FFFF00 80%);
}
#six a {
background:-webkit-linear-gradient(#990099, white 20%, #990099 80%);
background:-moz-linear-gradient(#990099, white 20%, #990099 80%);
background:linear-gradient(#990099, white 20%, #990099 80%);
}
#seven a {
background:-webkit-linear-gradient(#3366FF, white 20%, #3366FF 80%);
background:-moz-linear-gradient(#3366FF, white 20%, #3366FF 80%);
background:linear-gradient(#3366FF, white 20%, #3366FF 80%);
}
#eight a {
background:-webkit-linear-gradient(#FF9900, white 20%, #FF9900 80%);
background:-moz-linear-gradient(#FF9900, white 20%, #FF9900 80%);
background:linear-gradient(#FF9900, white 20%, #FF9900 80%);
}
#jsddm {
width: auto;
height:auto;
text-align:center;
margin-left:-42px;
margin-top:-10px
}
#jsddm li {
text-align:center;
padding: 0.5px;
display: inline;
width:auto;
height:inherit;
float: left;
}
#jsddm li a:hover {
color: #AAD036;
text-shadow:-1px 0 #669933, 0 1px #669933, 1px 0 #669933, 0 -1px #669933;
font: 16px Calibri;
padding-top: 6px;
font-weight: bold;
padding-bottom: 6px;
}
</style>
html로 :
<ul id="jsddm">
<li id="one"><a href="index.html">About</a></li>
<li id="two"><a href="http://http://www.android.com/">Official Page</a></li>
<li id="three"><a href="http://developer.android.com/index.html">Developers</a></li>
<li id="four"><a href="https://play.google.com/store">Google Play</a></li>
<li id="five"><a href="http://www.android.com/phones-and-tablets/">Phones & Tablets</a></li>
<li id="six"><a href="http://www.android.com/versions/kit-kat-4-4/">Kit Kat (4.4)</a></li>
<li id="seven"><a href="http://www.android.com/apps-and-entertainment/">Entertainment</a></li>
<li id="eight"><a href="https://plus.google.com/+android/posts">Google+</a></li>
</ul>
안녕 얘들 아, 내가 다른 색깔의 버튼이있는 JQuery와 헤더가
(리) 당신에게 고유 한 링크를 가져옵니다. 잘 작동하지만 Firefox와 Chrome에서는 각 버튼의 간격이 그림과 같이 다릅니다. 각 코드의 가로 세로 비율을 유지하기 위해 몇 시간 동안 코드를 변경했습니다. 나는 각 단추의 너비를 설정하는 범위까지 갔다. 이 문제로 나를 도와 줄 수 있니?
당신이 원하는 이유는 무엇입니까? .. 사람들은 어쨌든 두 가지를 모두 가지지 않을 것이며 어떤 것이 더 넓은 지 비교할 것입니다. 그리고 브라우저에 따라 약간 다르게 퍼져있는 다른 모든 텍스트는 어떻게 수정해야합니까? ... 내가 말하고자하는 바는 귀찮게하지 마라. 웹 사이트를 만드는 것보다이 작업을 수정하는 데 더 많은 시간을 할애해야한다. (그리고이 작은 차이점은 브라우저가 어떻게 글꼴을 렌더링하는지에 대한 것이다. 어쨌든 그들 – LGSon
당신은 reset.css를 사용하고 있습니까? 하나를 시도하지 않으면, 그것은 기본적으로 당신이 겪고있는 많은 도움이됩니다. – Tinfoilboy
@PellePenna 필자는이 JQuery 헤더를 자주 사용하며 항상 문제가되고있다. 단추가 주어진 머리글과 일치하지 않습니다. 그냥 엉성한 것처럼 보입니다. – l33tspeak