Timeline to XHTML 1.0 Transitional??

mpmcleodmpmcleod Registered Users Posts: 288 Major grins
edited February 5, 2009 in SmugMug Support
Any idea when SM will make their pages valid to XHTML 1.0 Transitional?
http://validator.w3.org/

One of my galleries has 170+ errors.

The biggest problem seems to be with ampersands.

Even the main home page, as simple as it is, doesn't validate.

Could we get these fixed? Maybe in the next release?
-- Mike

smugmug nickname: mpmcleod
http://www.michaelmcleod.com/

Comments

  • Mike LaneMike Lane Registered Users Posts: 7,106 Major grins
    edited June 7, 2006
    No need. Validation is nice, but not a requirement. I'm pretty sure everything that doesn't validate is part of a javascript. One way to prevent validators from choking on all the ampersands and less than signs is to make the javascript a CDATA section (surround the javascript with <![CDATA[ and ]]>) but from what I'm reading this potentially causes problems with with some web technologies (xml and xslt). I have no idea why SM has chosen not to make the javascripts a CDATA section but perhaps it's due to problems with parsing that I know nothing about. I'll see if JT can give us more info on the off chance that this isn't something that's on their radar.

    But the point is that validation is all the rage, but it's far from being required. Everything that you'll need to use from a customization standpoint is valid. If you find something in the xhtml or CSS that isn't valid post it in here and you'll see that it gets changed quickly. But javascripts won't ever validate in an xhtml validator and believe it or not, that's a-okay!
    Y'all don't want to hear me, you just want to dance.

    http://photos.mikelanestudios.com/
  • mpmcleodmpmcleod Registered Users Posts: 288 Major grins
    edited June 7, 2006
    Mike Lane wrote:
    No need. Validation is nice, but not a requirement. I'm pretty sure everything that doesn't validate is part of a javascript. One way to prevent validators from choking on all the ampersands and less than signs is to make the javascript a CDATA section (surround the javascript with <![CDATA[ and ]]>) but from what I'm reading this potentially causes problems with with some web technologies (xml and xslt). I have no idea why SM has chosen not to make the javascripts a CDATA section but perhaps it's due to problems with parsing that I know nothing about. I'll see if JT can give us more info on the off chance that this isn't something that's on their radar.

    But the point is that validation is all the rage, but it's far from being required. Everything that you'll need to use from a customization standpoint is valid. If you find something in the xhtml or CSS that isn't valid post it in here and you'll see that it gets changed quickly. But javascripts won't ever validate in an xhtml validator and believe it or not, that's a-okay!

    Thats all good to know.

    There are 10 errors on the main page alone that have nothing to do with javascript.

    3 are end tags </div> for which there is not a <div> open.
    -- Mike

    smugmug nickname: mpmcleod
    http://www.michaelmcleod.com/
  • Mike LaneMike Lane Registered Users Posts: 7,106 Major grins
    edited June 7, 2006
    I'm not seeing the extra tags on my homepage or your homepage . I am seeing 2 extra elements in the footer on my home page and yours. Also many (all?) of the input elements are not closed properly.

    On your page I am seeing two errors with p elements. You've got

    in an attempt to self-close a p element. You can't do that, you've got to have an opening and a closing element for the p tag (

    and

    ) since it is not a self-closing element in xhtml. You'd be better suited to use a
    element in those places it looks like to me.
    Y'all don't want to hear me, you just want to dance.

    http://photos.mikelanestudios.com/
  • bwgbwg Registered Users, Retired Mod Posts: 2,119 SmugMug Employee
    edited June 7, 2006
    mpmcleod wrote:
    Thats all good to know.

    There are 10 errors on the main page alone that have nothing to do with javascript.

    3 are end tags </div> for which there is not a <div> open.
    I agree with Mike, validation will get you a fancy w3 banner on your site, but that's about all it's good for. Also, a lot of times HTML Tidy (the w3 validator) will give a false error about a missing closing tag if there is an invalid attribute or other error higher up in the document. if you've ever worked with any type of compiler, they all do the same thing.

    Mike, the CDATA section is part of the XML spec so i'm interested to see where it would cause an issue w/XML and/or XSL (also still just XML). I'm not saying you're wrong, i've just never seen it and it causes no problems in sites i've done where i've wrapped my javascript with it. All it does is tell the XML parser not to worry about checking the data inside the CDATA section for invalid characters (ampersands, question marks, etc).
    Pedal faster
  • luke_churchluke_church Registered Users Posts: 507 Major grins
    edited June 7, 2006
    bigwebguy wrote:
    Also, a lot of times HTML Tidy (the w3 validator) will give a false error about a missing closing tag if there is an invalid attribute or other error higher up in the document. if you've ever worked with any type of compiler, they all do the same thing.

    I agree in many ways with what Mike + BWG have said, compliance to the spirit is more important than the law in HTML's case. (I use speech command software heavily, so I'm a big fan of alt tags on click-able images and the like)

    Hmmm... That's a bit pants. XHTML should be an easy language to do fault-propogation termination for.

    Modern compilers are a lot better at doing this kind of thing, MS' C# compiler generally only has a couple of pathological cases to do with structural deformations, compared to MS' C++'s which seems to have a few non-pathological cases.

    But, hey, writing error-propogation functions for compilers is a somewhat specialised interest of mine, so I will attempt not to migrate too far off-topic ;)

    I usually find, slightly ironically, that the slowest things on a couple of the websites I've written is W3 serving their icon :)

    Luke
  • AndyAndy Registered Users Posts: 50,016 Major grins
    edited June 7, 2006
    Thanks for posting Mike!
  • {JT}{JT} Registered Users Posts: 1,016 Major grins
    edited June 7, 2006
    Compared to other things I am working on - validation is one of my lowest priorities :)

    Mike and Lee nailed it - validation makes anal retentive people feel good (I am not pointing any fingers - I consider myself one of the most retentive :) ), but it does not make sure that all major browsers work on the page. For those keeping track: Opera, Camino and sadly - even my beloved Safari - are NOT major browsers.

    All jokes aside - I am certain some pages have extra tags. I don't have the bandwidth to comb through HTML for every page that someone creates. I surf the site with the HTML Tidy plugin for Safari (until the Firefox version works for MacIntel) and look down at all major errors I see. So eventually everything major will be fixed.

    mpmcleod wrote:
    Any idea when SM will make their pages valid to XHTML 1.0 Transitional?
    http://validator.w3.org/

    One of my galleries has 170+ errors.

    The biggest problem seems to be with ampersands.

    Even the main home page, as simple as it is, doesn't validate.

    Could we get these fixed? Maybe in the next release?
  • mpmcleodmpmcleod Registered Users Posts: 288 Major grins
    edited June 7, 2006
    {JT} wrote:
    Compared to other things I am working on - validation is one of my lowest priorities :)

    Mike and Lee nailed it - validation makes anal retentive people feel good (I am not pointing any fingers - I consider myself one of the most retentive :) ), but it does not make sure that all major browsers work on the page. For those keeping track: Opera, Camino and sadly - even my beloved Safari - are NOT major browsers.

    All jokes aside - I am certain some pages have extra tags. I don't have the bandwidth to comb through HTML for every page that someone creates. I surf the site with the HTML Tidy plugin for Safari (until the Firefox version works for MacIntel) and look down at all major errors I see. So eventually everything major will be fixed.
    Thanks for all the replies. I do understand there are reasons not to be standards compliant (like all the IE users out there). However, it does make it more difficult to debug code.

    Now for the real reason I asked the question. I was trying to figure out why my pages didn't look quite right and why some javascript that worked fine in FF didn't work in IE. I assumed that it was something I had done, like opening a tag and not closing it or something similar. Because SM is the very first place where I haven't had control over the entire document my first step was to validate the document. I was blown away by the sheer number of errors in the document. Because of this I was unable to even begin to look for open tags that were not closed. Turns out the problem has nothing to do with this (apparently has to do with how MS and JScript handles RegExp is different than javascript).

    JT, I certainly don't expect that you could, would or even should if you could (a little Dr. Seuss to lighten the mood:D) check everyone's pages for validation.
    Nevertheless, I wanted to check the pages that SM builds. When I said the main page I was referring to www.smugmug.com, a fairly simple page that should validate easily. Even this page generates 10 minor errors. These include a style definition in the body, mixed case attributes, duplicate alt tag in img, and an invalid alt tag in a.

    Thanks again for the comments. Good discussion.
    -- Mike

    smugmug nickname: mpmcleod
    http://www.michaelmcleod.com/
  • Mike LaneMike Lane Registered Users Posts: 7,106 Major grins
    edited June 7, 2006
    {JT} wrote:
    I surf the site with the HTML Tidy plugin for Safari (until the Firefox version works for MacIntel) and look down at all major errors I see.
    You're waiting for a universal binary of HTML Tidy or of firefox?
    Y'all don't want to hear me, you just want to dance.

    http://photos.mikelanestudios.com/
  • {JT}{JT} Registered Users Posts: 1,016 Major grins
    edited June 7, 2006
    Mike Lane wrote:
    You're waiting for a universal binary of HTML Tidy or of firefox?

    The universal binary plugin of HTML Tidy for Firefox :)
  • StevenVStevenV Registered Users Posts: 1,174 Major grins
    edited June 7, 2006
    boy wouldn't it be nice if the SM Customization page ran user's input through tidy (or similar) to make sure that as few user-induced errors get into the end code.
  • AllenAyresAllenAyres Registered Users Posts: 7 Beginner grinner
    edited October 15, 2008
    mpmcleod wrote:
    Any idea when SM will make their pages valid to XHTML 1.0 Transitional?
    http://validator.w3.org/

    (2 years later)

    Hello everyone :)

    I am trying to get my main site and my SM site to look the same, in IE7 it's not far off, but looks terrible in FF and Google's Chrome.

    http://www.bellafotografica.com/ vs. http://clients.bellafotografica.com/

    It really seems the difference between the 2 displays seems to be how FF and Chrome displays the "html 4.01" doctype vs. the "xhtml 1.0" doctype.

    Since I have no control over which browser my clients use, is there any update to when smugmug is going to support xhtml doctypes or can it be hacked already?
  • AllenAyresAllenAyres Registered Users Posts: 7 Beginner grinner
    edited October 15, 2008
    hmm... that's not it (tho it doesn't help).

    Something in the smugmug code is messing up the layout, maybe I need to wrap it in another div to ward off buglets.
  • AllenAyresAllenAyres Registered Users Posts: 7 Beginner grinner
    edited October 15, 2008
    header style conflicts, fixed by adding a style="width: 980px;" to the right div.

    It would be nice if SM updated/allowed xhtml doctypes, one less thing to consider when de-bugging sites :)
  • Mike LaneMike Lane Registered Users Posts: 7,106 Major grins
    edited October 19, 2008
    AllenAyres wrote:
    header style conflicts, fixed by adding a style="width: 980px;" to the right div.

    It would be nice if SM updated/allowed xhtml doctypes, one less thing to consider when de-bugging sites :)
    We switched from xhtml transitional to html 4.01 strict a while back (I don't remember when exactly, but over a year for sure). xhtml really isn't all it's cracked up to be despite what many of the hard core web d00ds will try to push on you. The fact of the matter is that very few sites actually use it properly (do your other sites use it properly?) and there are browser inconsistencies with CSS and JS.

    That being said, there are parts of our site that rely on the HTML 4.01 doctype to work properly. So, I'm afraid we can't allow our users to switch doctypes. Sorry about that!
    Y'all don't want to hear me, you just want to dance.

    http://photos.mikelanestudios.com/
  • AllenAyresAllenAyres Registered Users Posts: 7 Beginner grinner
    edited February 5, 2009
    Mike Lane wrote:
    We switched from xhtml transitional to html 4.01 strict a while back (I don't remember when exactly, but over a year for sure). xhtml really isn't all it's cracked up to be despite what many of the hard core web d00ds will try to push on you. The fact of the matter is that very few sites actually use it properly (do your other sites use it properly?) and there are browser inconsistencies with CSS and JS.

    Sorry for the late reply, after a couple days with no reply I didn't come back to look to see if there was a reply...

    xhtml is all it's cracked up to be, you just have to actually follow the rules when writing your code. When you do you get far fewer surprises when checking your site's display in browsers other than your favorite one.

    Yes, all my other sites use it properly - I was the guy who originally pushed to clean up all the *%(*& that passed for html in forums, galleries, etc. 8 years ago. Your own forum here displays pretty well in all browsers based on the work I did back then. So I must be one of those "hard core web doods". eek7.gif

    Seriously, when we try to integrate our sites with smugmug's application (like the sales pitch says we can) it would save most people a lot of time if the underlying code was up to standards set this century. rolleyes1.gif
Sign In or Register to comment.