Login Register






HTML positioning filter_list
Author
Message
HTML positioning #1
So I am coding a website I have nearly finished so I showed my work to some people and they told me that the website displays not in the middle of their screens. in my screen it is right in the center and on others its on the left side.
So how can I make sure that my website will be in the center on any screen and any resolution.

Reply

RE: HTML positioning #2
You are building the website on the resolution on your own screen.
To center it simply put a wrapper or a container around it and set the margin on 0px auto.

Reply

RE: HTML positioning #3
(11-29-2013, 11:26 PM)bluedog.tar.gz Wrote: You are building the website on the resolution on your own screen.
To center it simply put a wrapper or a container around it and set the margin on 0px auto.

could you write an example?

Reply

RE: HTML positioning #4
<div id="wrapper">
<div id="example">
I want this centered!
</div>
</div>

Then give #wrapper a margin of 0px auto with the desired width.

Reply

RE: HTML positioning #5
(11-30-2013, 02:07 AM)bluedog.tar.gz Wrote: <div id="wrapper">
<div id="example">
I want this centered!
</div>
</div>

Then give #wrapper a margin of 0px auto with the desired width.

Thank you

Reply

RE: HTML positioning #6
was wondering the same thing. Thanks you.

Reply