値 |
1値又は2値で指定 キーワードは、パーセンテージの値または、長さの値と 組み合わせることはできません。 1値指定の50%は縦横共に、 50%の意味になる。(50%=center) top leftとleft top = 0% 0% = 0% topとtop centerとcenter top = 50% 0% right topとtop right = 100% 0% leftとleft centerとcenter left = 0% 50% centerとcenter center = 50% 50% = 50% rightとright centerとcenter right = 100% 50% bottom leftとleft bottom = 0% 100% bottomとbottom centerとcenter bottom = 50% 100% bottom rightとright bottom = 100% 100% = 100% |
||||||||||
初期値 |
0% 0% |
||||||||||
%値の基準 | そのエレメント自身との相対値 | ||||||||||
適用 |
|||||||||||
しない |
全ての値 |
ソース |
表示&操作 |
スタイル部に、 body{background-image:url(../img/poko_b.png); と記述すると。 |
背景画像(バナー)が、ページの右端の 中央に表示されます。 |