Guest Cashster09 Posted May 4, 2009 Report Posted May 4, 2009 here is my html Same day service is available daily. Se habla español. and here is my css .redtextcenter { color: #ff0000; text-align: center; } not sure why it's not centering in either IE or FF
jlhaslip Posted May 4, 2009 Report Posted May 4, 2009 A span is an inline element which will not behave like a block element, therefore, they will not centre the same way. You will need to add some margin-left to the span to get it to move right. Or change it to a with a class that centres, similar to what you have there.
newseed Posted May 4, 2009 Report Posted May 4, 2009 (edited) tags are not the same as tags. The will only fill the width of what's inside the tags and so there is no way for it to align center. You can do 1 or 3 things: 1. Just use a tag with a class defining the styles you desire. 2. Just wrap a tag around the existing tag and give the tag a text-align: center. (Makes more sense to use option #1). or 3 Add display:block to the tag css. The will force the to be the full width of whatever div it resides in. Keep in mind that the tag is not a block element but instead an inline element. Edited May 4, 2009 by newseed
newseed Posted May 5, 2009 Report Posted May 5, 2009 Be sure to use tag appropriately. Proper: Heading One Heading Two relevant for content below relevant content for heading two Heading Three relevant for content below relevant content for heading three The h2 thru h6 heading tags are sub-section titles of the main heading tag (h1) and each should be given a short title for the following content that is relevant to it.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now