vycentrovani divu s width:auto
Napsal: 13 dub 2010 21:43
[syntax lang=xhtml]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style type="text/css">
#top {
text-align:center;
width:100%;
}
#inside {
width:auto;
text-align:left;
margin:0 auto;
}
</style>
</head>
<body>
<div id="top">
<div id="inside"> test </div>
</div>
</body>
</html>[/syntax]
mam tenhle kod a potrebuju nejak vycentrovat div #inside, ale aby mu zustal parametr width:auto
jde to nejak? dik
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<style type="text/css">
#top {
text-align:center;
width:100%;
}
#inside {
width:auto;
text-align:left;
margin:0 auto;
}
</style>
</head>
<body>
<div id="top">
<div id="inside"> test </div>
</div>
</body>
</html>[/syntax]
mam tenhle kod a potrebuju nejak vycentrovat div #inside, ale aby mu zustal parametr width:auto
jde to nejak? dik