HTML > CSS

関連トピックス



役立つサイト

サンプルダウンロードのページが参考になる。

memo

リセット CSS(2009.02.07の時点+コメントで説明つき)
/* 各要素のmargin.paddingの正規化 */
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;   
} 
/* tabel要素のセルのボーダーとボーダーの間隔を0に */
table {  
   border-collapse:collapse;   
   border-spacing:0;   
} 
/* fieldsetやimg要素のボーダーを削除 */
fieldset,img {    
   border:0;   
} 
/* font-styleやfont-weightプロパティの正規化 */
address,caption,cite,code,dfn,em,strong,th,var {  
   font-style:normal;   
   font-weight:normal;   
} 
/* ol、ul要素のlist-styleを削除 */
ol,ul {  
   list-style:none;   
} 
/* captionやth要素を左揃えに */
caption,th {  
   text-align:left;   
} 
/* 見出し要素のフォントサイズ、太さの正規化 */
h1,h2,h3,h4,h5,h6 {  
   font-size:100%;   
   font-weight:normal;   
} 
/* q要素の引用マークを削除 */
q:before,q:after {  
   content:'';   
} 
/* 略語のボーダーを削除 */
abbr,acronym { border:0;   
}  

タグの順番
/* mozilla.org Base Styles
* maintained by fantasai
* (classes defined in the Markup Guide - http://mozilla.org/contribute/writing/markup )
*/
/* Suggested order:
* display
* list-style
* position
* float
* clear
* width
* height
* margin
* padding
* border
* background
* color
* font
* text-decoration
* text-align
* vertical-align
* white-space
* other text
* content
*
*/



名前:
コメント: