SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Enthusiast CRYSTL's Avatar
    Join Date
    Sep 2003
    Location
    Kazakhstan
    Posts
    68
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Validity or filesize?

    I'm working on the new version of my website. I've already almost replaced all my tables with div's and just have checked XHTML for validity. After inserting all necessary quotemarks its valid. Huh.

    I can now remove all unnecessry tags (like </li> and </p> and some others), also remove quotation marks (e.g. href=/link instead of href="/link") and some else. So I'll decrease filesize. But this make the document not valid.

    Or I can left it valid, but it would be some 0.5-2 kilos thicker than example above.

    So, validity or filesize?

  2. #2
    "Of" != "Have" bronze trophy Jeff Lange's Avatar
    Join Date
    Jan 2003
    Location
    Calgary, Canada
    Posts
    2,063
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Validity. If you want to do all that other stuff, use HTML 4.01.
    Who walks the stairs without a care
    It shoots so high in the sky.
    Bounce up and down just like a clown.
    Everyone knows its Slinky.

  3. #3
    SitePoint Addict hurricane.uk's Avatar
    Join Date
    May 2003
    Location
    Liverpool
    Posts
    361
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by CRYSTL
    I'm working on the new version of my website. I've already almost replaced all my tables with div's and just have checked XHTML for validity. After inserting all necessary quotemarks its valid. Huh.

    I can now remove all unnecessry tags (like </li> and </p> and some others), also remove quotation marks (e.g. href=/link instead of href="/link") and some else. So I'll decrease filesize. But this make the document not valid.
    These are not unnecessary - closing tags are strictly required in xhtml, removing them wil invalidate your markup, quotes are also needed for attributes and link urls in your markup. Reduce your files sizes by using only semantic markup up your html files and place all style and positioning info in an external CSS file that you call using <link> or @import.

  4. #4
    SitePoint Addict
    Join Date
    Dec 2002
    Posts
    386
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    These tags are most important if you are going to be serving your page as xml, in which case they are essential!
    If you really want to save those bytes you really should do as suggested and try html 4 (plus you save more bytes right there... html vs Xhtml)

  5. #5
    SitePoint Zealot
    Join Date
    May 2003
    Location
    Dover, PA
    Posts
    135
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    One of the best ways to reduce the amount of data a user has to download while viewing a web site is to store your global style in a separately linked CSS document which is cached on the user's end. It sounds like you're already probably using CSS, so there's a big advantage right there. You won't save much (or enough to be worth the trouble) by removing those few things, I think.
    http://www.statgfx.com


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •