Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

CSS Help

Featured Replies

I cant center my site.....

 

i have absoluted some divs please advise what 2 do.

 

html{
overflow: auto;
margin:auto;
}

body{
margin: 0;
padding: 0;
font-size: 90%;
font-family: "Franklin Gothic Book";
color: #666666;
text-align:center;
background-image:url('images/trbg.png');
background-repeat: repeat-x;
}
#footer {
position: absolute; width: 600px; height: 60px; top: 560px;
margin: 0 auto;
width: 800px; 
text-align:center;
}
#logoContent {
position: absolute; width: 301px; height: 150px; z-index: 2; left: 282px; top: 4px;
text-align:center;
}
.footer {
color:#666666;
text-align:center;
font-family:inherit;
}
#contentMain {
position: absolute; width: 598px; height: 409px; z-index: 3; left: 155px; top: 146px;
}
h1 {
font-family: "Franklin Gothic Book";
font-size: 17pt;
color: #39aeae;
text-align:center;
}

Why not try adding margins? Plus and minus values both work and may help.

Use a wrapper, these act as drawing boards for all your content to go in.

 

So something like this:

 

body {
text-align:center;
}
#wrapper {
margin: 0 auto;
width: xxxx; /* Replace the xxxx with the the width of your site (eg 800px)*/
text-align:left;
}

 

Then for the HTML:

 

<div id="wrapper">
<!-- Place everything you want to be centred here-->
</div>

 

Should do the trick hopefully.

try changing

 

body{

margin: 0;

 

to

 

body{

margin: 0 auto;

 

hope that works for you.

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.