471,874 Members | 1,583 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,874 software developers and data experts.

Centering and image according to standards

I normally centre an image using a <p align="center"> ... </p> format, but I
understand that this is "deprecated" in the latest standard in favour of styles.
The problem is that I cannot find a style that will centre an image,
"text-align" doesn't work and probably shouldn't.

So what is the "standards-correct" method of centering an image?

TIA

.... Greg Shannan
Jul 20 '05 #1
2 1803
Greg Shannan wrote:
I normally centre an image using a <p align="center"> ... </p> format,
Your image constitutes an entire paragraph? <div> is likely to be more
apropriate.
but I understand that this is "deprecated" in the latest standard in
There's nothing in the word deprecated that makes it worthy of recieving
quote marks in the above.
favour of styles. The problem is that I cannot find a style that will
centre an image, "text-align" doesn't work
text-align does work, you just have to use it in the right place
and probably shouldn't.
It is badly named. inline-align might be better.
So what is the "standards-correct" method of centering an image?


http://dorward.me.uk/www/centre/#inline

--
David Dorward http://dorward.me.uk/
Jul 20 '05 #2
Thanks, the div suggestion does seem to work.

Sorry for the quote marks.

.... Greg Shannan

"David Dorward" <do*****@yahoo.com> wrote in message
news:bn*******************@news.demon.co.uk...
Greg Shannan wrote:
I normally centre an image using a <p align="center"> ... </p> format,


Your image constitutes an entire paragraph? <div> is likely to be more
apropriate.
but I understand that this is "deprecated" in the latest standard in


There's nothing in the word deprecated that makes it worthy of recieving
quote marks in the above.
favour of styles. The problem is that I cannot find a style that will
centre an image, "text-align" doesn't work


text-align does work, you just have to use it in the right place
and probably shouldn't.


It is badly named. inline-align might be better.
So what is the "standards-correct" method of centering an image?


http://dorward.me.uk/www/centre/#inline

--
David Dorward http://dorward.me.uk/

Jul 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

18 posts views Thread by Heath | last post: by
2 posts views Thread by Ryan W Sims | last post: by
1 post views Thread by John Leeke | last post: by
6 posts views Thread by Jerry Camel | last post: by
3 posts views Thread by John Pote | last post: by
reply views Thread by laredotornado | last post: by
reply views Thread by YellowAndGreen | last post: by
reply views Thread by zermasroor | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.