It appears you have not yet registered with DEVPPL. To register please click here... (it's fast, easy and free!)

Forum

Log In Sponsors
Board index Programming HTML Forum

Need Help To Align Page

Need Help To Align Page

Postby cuban on Sat Feb 10, 2007 6:16 pm

I need to center the content of a design that is currently left-justified.
Is this done via a code in the style.ccs or in the main html?

<p align="center"></p> does not move it for what I have to do.

I've put the template shell up so you can see what I mean.
http://www.actworld.co.uk/index-2b.html

I'd really appreciate an answer to what is, I assume, a simple and basic question.

Thank you.
cuban
 
Posts: 3
Joined: Mon Feb 05, 2007 1:49 am

Postby ramnosity on Sun Feb 11, 2007 3:01 am

If you want to center align try is in CSS, try


Body {
text-align: center;
}


I'm pretty sure that's how you do it in CSS.
Hope it helps.
Tenbucktunes Music for ten bucks or less
Image
User avatar
ramnosity
100+ Club
 
Posts: 196
Joined: Sat Feb 10, 2007 6:18 am
Location: at my computer

Postby cuban on Sun Feb 11, 2007 10:08 am

Thanks ramnosity, sadly that did not resolve it - can anyone else suggest anything?
cuban
 
Posts: 3
Joined: Mon Feb 05, 2007 1:49 am

Postby ReFredzRate on Sun Feb 11, 2007 10:51 am

Dammit, everybody want's to know how to do this nowadays. I've been working on this question for about 2 years, but I can't resolve the problem either :(
ReFredzRate
1000+ Club
 

Postby ramnosity on Sun Feb 11, 2007 7:22 pm

That is weird, it doesn't work. You could use Div or Span to label the text and then set the accual pixel location. But that would look a little different on different size screens I think. Just a seggestion.
Tenbucktunes Music for ten bucks or less
Image
User avatar
ramnosity
100+ Club
 
Posts: 196
Joined: Sat Feb 10, 2007 6:18 am
Location: at my computer

Postby Earache on Tue Feb 20, 2007 8:13 pm

I've seen this work a couple times. Turn your page into a three column table, with the left and right columns set to 50%.

for example:

<table>
<tr>
<td width="50%"></td>
<td>Your site code</td>
<td width="50%></td>
</tr>
</table>

I would recommend using CSS instead of using the "width" attribute in code, but you should get the gist of it.

I can't guarantee it will work crossbrowser, but I have seen it work.
Earache
 
Posts: 0
Joined: Tue Feb 20, 2007 8:05 pm
Location: Foxoborough, MA

Postby abhijeet_thomas on Wed Feb 21, 2007 9:14 am

I saw the url that you have mentioned. I see that inside the <p></p> tag you have subscribe and unsubscribe options with radio button and they seem to be center alligned. Where is the problem then?

are you trying to align the whole page in the center of the browser?
User avatar
abhijeet_thomas
 
Posts: 36
Joined: Mon Feb 19, 2007 10:57 am


Who is online

Users browsing this forum: No registered users and 6 guests