Центриране

JusT

Registered
Как да си центрирам сайта: royalbg.tk
index.php
Код:
body {

margin-top:-375px;
color: #000;
font: 18px Comic Sans MS, georgia, arial, verdana, sans-serif;
background-color:#e6e6e6;
position:absolute;
}
#b {z-index:10px; float:left;}
#bizon { margin:-980px 0 0 400px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; }
#krava { margin:-980px 0 0 400px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; }
#text { margin:-49px 0 0 -274px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; position:relative;}
#ss { margin: -100px 0 0 -310px;}
a:link
{
   color: #000;
   text-decoration: none;
}

a:visited
{
   text-decoration: none;
   color: #000;
}

a:hover
{
   color: #000;
}

a:active
{
   color: #000;
}

</style>
</head>


<body>

   <div style="margin:360 0 0 0; ">

   <div style="background: url('images/background.gif') no-repeat; width:1024px; height: 1280px; margin: 0px auto;"></div>
<div style="margin:-1005px 0px 400px 596px; ">

   <div style="background: url('images/cont.gif') no-repeat; height:684px; widht: 556px; margin: 100px 0 0 0;"></div>
   <div style="margin: -630px 0 0 60px ;">
   <div style="background: url(images/top.gif) no-repeat;widht: 565px; height: 25px;"></div>
   <div style="background: url(images/left.gif) no-repeat; width:20px; height:367px; margin:0 1000px 0 0px;"></div>
   <div style="margin:-372px 0px 0 15px; background: url(images/mid.gif) no-repeat; width: 565px; height: 365px;">   
   </div>
   <div style="background: url(images/bot.gif) no-repeat; widht:566px; height:25px;"></div>
   <div style="margin:-390px 0px 0px 545px; background: url(images/right.gif) no-repeat; widht:20px; height:367px;" ></div>
   </div>
   </div>
   
   </div>
+1 за който ми помогне и моля давайте ми целия код :)[/quote]
 
Така?
body {
margin-top:-375px;
color: #000;
font: 18px Comic Sans MS, georgia, arial, verdana, sans-serif;
background-color:#e6e6e6;
position:absolute;
}
#b {z-index:10px; float:left;}
#bizon { margin:-980px 0 0 400px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; }
#krava { margin:-980px 0 0 400px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; }
#text { margin:-49px 0 0 -274px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; position:relative;}
#ss { margin: -100px 0 0 -310px;}
a:link
{
color: #000;
text-decoration: none;
}

a:visited
{
text-decoration: none;
color: #000;
}

a:hover
{
color: #000;
}

a:active
{
color: #000;
}

</style>
</head>


<body>
<div align="center">
<div style="margin:360 0 0 0; ">

<div style="background: url('images/background.gif') no-repeat; width:1024px; height: 1280px; margin: 0px auto;"></div>
<div style="margin:-1005px 0px 400px 596px; ">

<div style="background: url('images/cont.gif') no-repeat; height:684px; widht: 556px; margin: 100px 0 0 0;"></div>
<div style="margin: -630px 0 0 60px ;">
<div style="background: url(images/top.gif) no-repeat;widht: 565px; height: 25px;"></div>
<div style="background: url(images/left.gif) no-repeat; width:20px; height:367px; margin:0 1000px 0 0px;"></div>
<div style="margin:-372px 0px 0 15px; background: url(images/mid.gif) no-repeat; width: 565px; height: 365px;">
</div>
<div style="background: url(images/bot.gif) no-repeat; widht:566px; height:25px;"></div>
<div style="margin:-390px 0px 0px 545px; background: url(images/right.gif) no-repeat; widht:20px; height:367px;" ></div>
</div>
</div>

</div>

</div>
 
пробвай така но не сам сигурен заштото не 4аткам мн хтмл и цсс и след боди сложи <center> и преди затваряне на боди </center>
 
Тага <center></center> не се използва вече. Браузърите го четат но до кога не се знае. Нека му се реши проблема сега а не после пак да има проблем.
 
<head>
<style type="text/css">
div#container
{
position:relative;
width: 1000px;
margin-top: 0px;
margin-left: auto;
margin-right: auto;
text-align:left;
}
body {text-align:center;margin:0}
</style>
<style type="text/css">
body {
margin-top:-375px;
color: #000;
font: 18px Comic Sans MS, georgia, arial, verdana, sans-serif;
background-color:#e6e6e6;
position:absolute;
}
#b {z-index:10px; float:left;}
#bizon { margin:-980px 0 0 400px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; }
#krava { margin:-980px 0 0 400px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; }
#text { margin:-49px 0 0 -274px; font: 25px Comic Sans MS, georgia, arial, verdana, sans-serif; position:relative;}
#ss { margin: -100px 0 0 -310px;}
a:link
{
color: #000;
text-decoration: none;
}

a:visited
{
text-decoration: none;
color: #000;
}

a:hover
{
color: #000;
}

a:active
{
color: #000;
}
</style>
</head>

<body>
<div style="position:absolute; overflow:hidden; width:1000px; z-index:0">

<div style="margin:360 0 0 0; ">

<div style="background: url('images/background.gif') no-repeat; width:1024px; height: 1280px; margin: 0px auto;"></div>
<div style="margin:-1005px 0px 400px 596px; ">

<div style="background: url('images/cont.gif') no-repeat; height:684px; widht: 556px; margin: 100px 0 0 0;"></div>
<div style="margin: -630px 0 0 60px ;">
<div style="background: url(images/top.gif) no-repeat;widht: 565px; height: 25px;"></div>
<div style="background: url(images/left.gif) no-repeat; width:20px; height:367px; margin:0 1000px 0 0px;"></div>
<div style="margin:-372px 0px 0 15px; background: url(images/mid.gif) no-repeat; width: 565px; height: 365px;">
</div>
<div style="background: url(images/bot.gif) no-repeat; widht:566px; height:25px;"></div>
<div style="margin:-390px 0px 0px 545px; background: url(images/right.gif) no-repeat; widht:20px; height:367px;" ></div>
</div>
</div>

</div>

Там където е с червено сложи ШИРИНАТА
 
Нестава, проблема е че сайта за да се види треа да се скрола настрани иначе като гледам си е центриран просто тфа скролиране ..
 
Мда, и с малко корекции се получи , мерси на всички , но +1 получава @DeathGuard_ :)
 

Горе