I'm just wondering why the majority of the themes are XHTML Strict, including the ones packaged w/Drupal?

XHTML transitional would be much more logical. don't ya think?

*other statements retracted.. (edit)

Comments

Anonymous’s picture

If you are lazy and want to use legacy code, you can use XHTML transitional.
If you want to respect web standards and totally separate content from presentation, use XHTML strict.
I believe that the theming community of Drupal is doing the right thing.

exorb’s picture

It's not a matter of being lazy. It's the fact that Java Applets, Flash, most all text editors, and even something as simple as an external link in new window - is not XHTML strict complaint.

So if your running *any kind of ad you've broken the XHTML Strict standards.

Most use JavaScript to hack the DOM to be complaint - IE Jquery (so what's really the point here? )
I'd also like to mention that 'over-lapping' tags are illegal in XHTML strict as seen in the drupal core.

exorb’s picture

I'm not here to start a debate. But, XHTML Strict standards don't follow "real world" web-site needs.

+ XHTML is making HTML more like XML (a service) - the problem with that is that a web application might not want to be "a service". Personally I don't want programed "bots" to exploit my entire site.

any can walk the Document Object on any XHTML Strict site and 'dig' for forms submit them and read the output w/ a program. (and w/ very little effort) as much effort as it is to parse an XML file.
Captcha - is not near enough and there are image processors that can see those symbols. Spider/Robots have them built in already.

The truth is that "the XHTML standards push" is a hackers dream come true.

bfitzgerald’s picture

not really, xhtml strict is not that hard really. have you heard of HTML tidy?
It makes cross browser styling alot easier I have found.

you are commiting to set of rules of how the page should appear. once you have that done debugging the html is easier. Also all other ie problems are well documentated at this stage.

exorb’s picture

Because we care about standards.

fair enough!
- ignore me fellas. :)

Drupal is cool.

exorb’s picture

Drupal Core is not XHTML Strict.

Items that need fixing -

* over-lapping tags need to be removed. Overlapping Div tags everywhere! (and if removed they might break the functionality.)
INPUT TAGS need to be 'self closing' they are not.
Line breaks - in user submitted comments are not self closing (BR TAG missing slash)
IMG tags need to be self closing.

adding to list.

Drupal Core is not even XHTML Transitional complaint. Let's shoot for Transitional first, don't ya say?

exorb’s picture

50 errors found on the home page of this site!
85 elements that are not complaint.

http://validator.w3.org/check?uri=www.drupal.org&charset=(detect+automatically)&doctype=Inline&group=0

note those errors are for 'transitional' not even strict.
If i run a 'strict' test it would be about 100 errors and warnings.

and that's just page one.

That's my point.

exorb’s picture

40 Errors, 35 warning(s) "transitional " for this very page. and there is not even a lot going on w/it.

http://validator.w3.org/check?uri=http%3A%2F%2Fdrupal.org%2Fforum%2F3&ch...(detect+automatically)&doctype=Inline&group=0&user-agent=W3C_Validator%2F1.654#result

exorb’s picture

If you want to follow CSS "standards" as well

- just in case you do =
this page has 143 CSS ERRORS and Warnings declariations that so not meet basic CSS standards

So we are looking at over 200 erros/warnings on this page alone (by standards).

If i want to make my page 'transitional' it's not because i'm lazy(if i wanted to follow standards i'd have a crap load of rewriting to do)

I think drupal is cool - but to push XHTML Strict standards with it is a far reach.
And 80% of sites would be much more optimal going w/ transitional. take my word for it.
Drupal.org is 'transitional'
why ? because it's the real world.

Jeff Burnz’s picture

I think you are confusing Drupal core (what you download and install) with d.o's theme and content.

Thrown mud rarely sticks, but cleaning it up, that's something to be proud of ;)

exorb’s picture

nope. I'm talking about the 'core' +++ and or themes that come with drupal out of the box.
they did fix some of these in the last update.

a simple view of the source in firefox will should show some blatant unclosed tags.
you can start with the head content not being self closed tags.
- they will be marked in 'red' -

there are many tags through out like image and form field (as well as line breaks in comments) tags that are not 'self-closing' and they should be.

That's pretty much the 'very basic' idea behind XHTML. close all tags. you could not get a drupal site to pass XHTML strict validation with out editing many parts of the core (or even transitional for that matter) - to include the form api , the comments module... for starters.

regardless i'm finding drupal to be pretty cool. still learning.

exorb’s picture

if you want a specific example - look at the login form field tags - they need back slashes to be 'self closing'

http://www.w3schools.com/Xhtml/xhtml_syntax.asp

Jeff Burnz’s picture

The input filter "Lines and paragraphs break automatically" uses self closing break elements, maybe you are using a WYSIWYG editor?

Drupal validates mate, believe me, you need to look for the mistake in your own work or the theme you are using etc.

Not really sure what form you are looking at (but I assume you mean the input elements?)

input element from D6 user login block...
<input id="edit-name" class="form-text required" type="text" value="" size="15" name="name" maxlength="60"/>

BTW, join the accessibility group and have some input there, certainly if there are themes that don't validate (and they really should) thats a good place to bring it up. http://groups.drupal.org/accessibility