Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 5 of 5
  1. #1
    Member FlameOut's Avatar
    Join Date
    Apr 2004
    Location
    Pittsburgh, PA
    Posts
    37
    Member #
    5669
    This seems to be harder than I thought. I recently bought the book "Sams, Teach yourself HTML and XHTML" and have been using what I've read, but if I try to make sure it's HTML4 compliant by going to Site Valet I get tons of errors. I even checked a site from the book and it gave more errors than my page.

    Should I even worry about this? Even it the book, it mentions both <center> and <p align="center"> as ways to center text. I thought <center> was the old way??

  2.  

  3. #2
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    <center> is extremely deprecated. Use
    Code:
    <div style="text-align:center">
    The specific errors might help.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  4. #3
    Senior Member Trico's Avatar
    Join Date
    Feb 2004
    Location
    Nottingham, UK
    Posts
    894
    Member #
    5081
    I'd recommend the official W3C Validator as opposed to others... both methods seem old, xhtml relies heavily on CSS to control text, but I imagine one of the methods you mentioned would work under transitional.

    <div style="text-align: center;">This text is centered.</div>

    (ah well he beat me to it.)

  5. #4
    Member FlameOut's Avatar
    Join Date
    Apr 2004
    Location
    Pittsburgh, PA
    Posts
    37
    Member #
    5669
    Quote Originally Posted by filburt1
    <center> is extremely deprecated. Use
    Code:
    <div style="text-align:center">
    The specific errors might help.
    I knew <center> was depreciated, but I thought it was replaced with <div align="center"> and <p align="center">. The book I have doesn't even mention <div style="text-align:center">, but when I replaced mine with that, at least that error was gone.

    I went and read some online sites before replying here. It seems like XHTML is going to be more complicated to learn than HTML.

    Is it even ok to post basic questions here, or are these forums mainly for mor advanced users?

  6. #5
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    The code I posted uses CSS which is becoming preferable to using attributes for formatting.

    You may post questions of any difficulty level.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 06:30 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com