How to get the image to the center

Hi,
please help how to get the image to the center in php file!

Thank You!
Code is here:

<?php $image = "wp-content/uploads/2012/11/boarder2.jpg"; $width = 900; $height = 23; echo ''; ?>

[php]

[/php]

the rest should be done in css…
try using “margin: 0 auto”

Added note: The addition of “px” to the original code is an error because you do not use the “px” in HTML.
It is used in CSS to indicate “pixels”. In HTML, it is just the number. You can add HTML to the line if you wish
to center the picture. Just add center tags, “…” around the image in your current code.
To center in HTML, use tags, in CSS, you use “align” commands or set margins or many other ways.

And, yes, this is usually done in CSS these days, as mdahlke stated.

Sponsor our Newsletter | Privacy Policy | Terms of Service