2011-11-24 86 views

回答

0

這裏是我做的方式,它消除並中和HTML元素的不一致的默認樣式。首先,我重新使用yui reset樣式表:

/* RESET 
--------------------------- 
Yahoo Reset 
version: 3.3.0 
build: 3167 
*/ 
html{color:#000;background:#FFF;}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,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;}li{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;font-variant:normal;}sup{vertical-align:text-top;}sub{vertical-align:text-bottom;}input,textarea,select{font-family:inherit;font-size:inherit;font-weight:inherit;}input,textarea,select{*font-size:100%;}legend{color:#000;} 

,然後我用yahoo css基地申報樣式普通的HTML元素:

/* BASE 
-------------------------------------- 
Yahoo Base 
version: 3.3.0 
build: 3167 
*/ 

h1,h2,h3{margin:1em 0;}h1,h2,h3,h4,h5,h6,strong{font-weight:bold; color:#333}abbr,acronym{border-bottom:1px dotted #000;cursor:help;}em{font-style:italic;}blockquote,ol,dl{margin:1em;}ol,dl{margin-left:2em;}ol li{list-style:decimal outside;}dl dd{margin-left:1em;}th{font-weight:bold;text-align:center;}caption{margin-bottom:.5em;text-align:center;}fieldset,table,pre{margin-bottom:1em;} 
+0

生病了試試看。謝謝。 – WillingLearner

+0

我已重置我的CSS,但事情仍然關閉在我的元素1的Firefox。我現在需要專門做一個規則... 1套Safari瀏覽器的說明,另一套適用於Firefox。我如何爲這兩款瀏覽器做一筆利潤率保證金? – WillingLearner