我已经问过这个问题了,但找不到问题的原因( My dropkick plugin's dropdown looking strange )
出于某种原因,它看起来像这样 ->
我不明白为什么,但我的代码在 jsfiddle 中工作正常 -> http://jsfiddle.net/UL4Tu/5/
这是我的 html:
<select name="fashion" class="default" tabindex="2">
<a class="dk_toggle" style="width: 245px; ">
<option value="Fashion">Fashion</option>
<option value="Health">Health</option>
<option value="Travel">Travel</option>
<option value="Food">Food</option>
<option value="Coupons">Coupons</option>
</select>
我的代码:
$('.default').dropkick();
我的 application.css 文件:https://dl.dropbox.com/u/86122402/files/application.css
最佳答案
嘿,现在的问题是我认为你没有使用css reset请使用这个
更多信息 http://meyerweb.com/eric/tools/css/reset/
习惯了
body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,textarea,p,blockquote,th,td {
margin:0;
padding:0;
}
table {
border-collapse:collapse;
border-spacing:0;
}
fieldset,img {
border:0;
}
address,caption,cite,code,dfn,em,strong,th,var {
font-style:normal;
font-weight:normal;
}
ol,ul {
list-style:none;
}
caption,th {
text-align:left;
}
h1,h2,h3,h4,h5,h6 {
font-size:100%;
font-weight:normal;
}
q:before,q:after {
content:'';
}
abbr,acronym { border:0;}
关于html - 我的 dropkick jquery 列表看起来不正确,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11356910/