Els said:
"Paul Furman" <
[email protected]> skrev i meddelandet
I used this style (38.css) at
http://www.scaiecat-spa-gigi.com/sv/test.html
but the list is still on the left
[snip stylesheet]
If you want to center something by using left and right
margins, you should also define a width.
Either define width and set the margins to auto, or define
the margins and set the width to auto.
I think you are right about the need of defininge a the margins and set
the width to auto or viceversa but the code which I wrote below and I used
as 38.css ( trying to get a better effect) is unfortunately not for a list
which does not have css bullets and is written horizontally. What is wrong
with it?
p{
margin-bottom: 2%;
margin-top: 2%;
text-indent:5%;
text-align: left;
margin-left:10%;
margin-right:10%;
}
TABLE { border-collapse: separate;
border: 1px solid red;
}
..one {color:#000000; border: 1px solid white;
background: #ffffff;}
..two {color:#000000; border: 1px solid white;
background: #33ffcc;}
..three {color:#000000; border: 1px solid white;
background: #99ff66;}
..four {
color:#ffffff; border: 1px solid white;
background: #cc6600;}
..five {color:#ffffff;
border: 1px solid white;
background: #ff0099;}
th, li, h1, h2, h3, a {
color: black;
background: transparent;
text-align:center;
}
body {
background: #ffffcc;
color: black;
font-size: 100%;
margin: 0;}
#head{border:0px solid white;}
#content{
margin-left:auto;
border:1px solid green;}
DIV.normal{margin-top: 5%;
}
div#menu{color:#000000;
background:#ffffcc;
width:25ex;
border:1px solid white;
text-align:center;
float:left;}
#menu a {
margin-left:auto;
margin-right: auto;
color: #0000ff;
background:#ffcc66;
border-left: 1px solid #F66460;
border-top: 1px solid #F66460;
border-right: 1px solid #000000;
border-bottom: 1px solid #000000;
width: 80%;
margin-top: 5px;
display: block;}
#menu a:active {color: #0000ff; background-color:#ffffff; }
#menu a:visited {color: #000000; background-color:#ffffff;}
#menu a:hover {
color: #666666;
background-color:#ffffff;
border-left: 1px solid #000000;
border-top: 1px solid #000000;
border-right: 1px solid #F66460;
border-bottom: 1px solid #F66460;}
div.top {margin-top: 2%;
margin-left: auto;
margin-right:auto;
text-align:center;
}
div.bottom {margin-bottom: 2%;
margin-left: auto;
margin-right:auto;
}
div.ulmenu {
display: inline;
list-style-type: none;
margin:auto;
padding: 0;
text-align:center;
width:50%
}
#navigation li {
display: inline;
list-style-type: none;
}
ul {
list-style:none;
margin:auto;
}
</style>