Categories
Specs Web

Google’s Ta Da moments

Recovered from the Wayback Machine.

Henri Bergius wrote a piece on Google’s seeming desire to replace all web components, except HTML. Among the “new” technologies:

  • SPDY to replace HTTP
  • schema.org and Microdata to replace a decade’s worth of semantic work with RDF and microformats
  • WebP, a new image format
  • WebM, a new video format
  • And now Dart, to replace JavaScript

However, I wouldn’t leave HTML out. The only editor for HTML5 is a Google employee, Ian Hickson, who has been working with other folks, including another Google employee, to break pieces off the HTML5 specification, take them to WHATWG space, and completely re-write them in isolation. Then, when the pieces are re-written, the editors don’t seem want to bring them back to the W3C. (Or they have to ask Google Legal whether they can do so, completely ignoring the fact that as a W3C member, Google pledged to work with others.)

I’ve been battling this effort with the Editing API and just recently, the same thing happened with the section on dynamic markup insertion.

It’s not that people aren’t happy about these non-HTML components being pulled out of the HTML5 specification, but rather than work with the members of the HTML WG and the W3C, Google has been encouraging people to act unilaterally, aided and abetted by the HTML5 editor.

What’s ironic is that the concepts behind the Editing API and the dynamic markup insertion sections, which includes innerHTML among other things, actually originated with Microsoft. I’ve been waiting for Microsoft to go, “Hold on partner!” Apple already has. (And again).

Google has become all that is arrogant conceit. It believes it can do anything better than anyone else. It has dropped any pretense of seemingly wanting to work with others, and pretends its work is open, as long as it “gives” it all away when it’s finished.

The internet and the web were created so that people could connect; that those who were separated physically could still work together. The roots of the web are based in openness and cooperation, not unilateral decisions that demonstrate little tolerance and no empathy. I’d rather use an imperfect technology created by a team of varied and interested people, then a “perfect” work created in isolation and dumped on the world in some grand “Ta Da!” moment.

An imperfect technology can be perfected, but you can’t fix hubris.

Categories
HTML5 Specs SVG

This page isn’t valid…and who cares

I covered my recent experiments in using SVG in HTML in SVG in HTML. I linked two different example pages with SVG inline in HTML: one dependent on HTML5 parsing (Firefox nightly), the other using the library, SVGWeb.

There’s another difference between the two examples other than just their implementation. The first example, dependent on a browser parsing the page as HTML5, doesn’t validate. The example using SVGWeb, does. Yet, both pages display correctly, as long as you use an HTML5 enabled browser for the first. The odder thing is, neither page is “invalid”.

The HTML markup is fine for both, as is the SVG used. However, the Validator doesn’t like inline SVG at this time, because, we’re told, no browser implements SVG inline in HTML, yet. The SVGWeb example validates because the SVG is contained in a script block. The validation problems with the first example go beyond embedding the SVG element directly in the web page, though. The example also incorporates a metadata element in the SVG that contains RDF/XML.

Embedding RDF/XML into the metadata element is perfectly valid with SVG, and in fact, quite common when people attach Creative Commons licenses to their work. The HTML5 Validator, though, doesn’t really know what to do with this RDF/XML. Why? Because RDF/XML uses namespaced elements, and namespaced elements are taboo in HTML. Yet, SVG is acceptable in HTML5.

Herein we discover the paradox that is HTML5: XML allowed in HTML, but parsed as HTML; extensible namespaced elements that are valid in SVG/XML, becoming invalid when embedded in the non-extensible environment that is HTML5. HTML5 as XHTML likes namespaces. HTML5 as HTML does not like namespaces. But HTML5, as both XHTML and HTML likes SVG, and SVG likes namespaces.

Pictorially, the logic of this looks about as follows (which would not be valid if inserted into an HTML5 HTML document):

Ouroborous

Oh, what is a web designer/developer to do, who just wants to use a little SVG here and there? Enter, stage left, the HTML5 Doctor.

Recently the HTML5 Doctor was asked about attributes and elements from HTML4 that are now obsolete but conforming (or not) in HTML5. Won’t adding a HTML5 DOCTYPE while still using these elements cause the pages to be invalid?

The Doctor’s answer:

While validation is undoubtedly important for your markup and your CSS, in my opinion it isn’t crucial to a site. Allow me to explain, we recently received a couple of emails pointing out that this site doesn’t validate. While there were some errors that have now been corrected, a primary reason why is the use of ARIA roles in the markup. These attributes currently aren’t allowed in the current specification, however there is work underway to make this happen.

To illustrate this point let’s look at Google, the search giant. If you look at the source on Google’s search pages you’ll see they use the HTML 5 doctype.

<!DOCTYPE html>

However, those pages don’t validate because they use the font and center elements amongst others things that we already know have been removed from the specification. Does this mean that users stop visiting Google? No.

Remember too that the specification is yet to be finalised and may still be changed (thus breaking you’re perfectly valid docments), in partnership with this changes to the specification may not immediately take be implemented in the validators. We also need to bear in mind that HTML 5 takes a “pave the cowpaths” approach to development, meaning that the Hixie, et al will look at what authors already do and improve upon it.

The days of validation being an end all, be all, are effectively over with HTML5. By obsoleting (not deprecating) elements that were perfectly valid in HTML4; by not providing an extensibility path within HTML in HTML5, especially considering that new elements will arise over time—not to mention, the inclusion of perfectly legitimate namespaces elements in SVG— all, combined make “validation” a goal, but not an end when it comes to the web pages of the future. We’re more likely to define a set of supported browsers and user agents and worry more about the pages working with these, then be concerned about whether the pages validate in Validator.nu.

So, my one web page with the inline SVG works with the Firefox nightly, with HTML5 parsing enabled. It isn’t valid…but who cares?

Categories
Specs Technology Web

Why read about it when you can play?

Earlier today I got into a friendly discussion and debate on Twitter about a new web site called W3Fools. The site bills itself as a “W3Schools intervention”, and the purpose is to wake developers up to the fact that W3School tutorials can, and do, have errors.

The problem with a site like W3Fools, I said (using shorter words, or course, since this was Twitter), is that it focuses too much on the negative aspects of W3Schools, without providing a viable alternative.

But, they said, W3Fools does provide links to other sites that provide information on HTML, CSS, or JavaScript. And, I was also told, the reason W3Schools shows up first in search results is because of uncanny use of SEO optimization.

Hmmm.

It may be true that W3Schools makes excellent use of SEO, and it may be equally true that W3Schools commits egregious and painful errors. However, neither of these account for what W3Schools is doing right. If you don’t acknowledge what the site does well, you’re not going to make much headway into turning people off the site—no matter how many cleverly named sites you create.

For instance, one of the superior information sites recommended by W3Fools is the Mozilla Doc Center, or MDC as it is affectionately known. Now, I’m a big fan of MDC. I use it all the time, especially when I want to get a better idea of what Firefox supports. But look at the work you have to put in to learn about a new HTML5 element, such as the new HTML5 hgroup element:

  1. Go to main page
  2. Click on HTML5 link
  3. Search through the topics until you see one that’s titled “Sections and outlines in HTML5”, which you know you want because it mentions hgroup
  4. Have a neuron fire and realize that you can just click directly on hgroup
  5. Go to the hgroup page, past the disclaimer about what version of Firefox supports the element, looking for an example of usage
  6. Realize there is no example of how to use hgroup
  7. Go to the original Sections and Outlines in HTML5 link
  8. Go past some stuff about elephants, looking for example
  9. Go past some bullets about why all this new sectioning stuff is cool, looking for an example
  10. Break down and use your in-page search to find hgroup
  11. Finally find an example of how to use hgroup

As compared to W3Schools:

  1. Go to main page
  2. Click on Learn HTML5 link
  3. Click on New Elements link
  4. Start to scroll down when you realize the new elements are listed along the left side
  5. Click on hgroup
  6. Look at example

One thing W3Schools does well is provide a clean, simple to navigate interface that makes it very easy to find exactly what you need with a minimum of scrolling or searching.

Returning to our comparison between W3Schools and MDC, we then search for information on SQL. Oh, wait a sec: there isn’t anything on SQL at the Mozilla site. That’s because Mozilla is primarily a browser company and is only interested in documenting browser stuff.

So then our intrepid explorer must find another site, this one providing information on SQL. And if they want to learn more about PHP, they have to find yet another site. To learn about ASP? Another site, and so on.

What W3Schools also provides is one stop shopping for the web developer. Once you’ve become familiar with the interface, and once the site has proved helpful, you’re more likely to return when you need additional information. Let’s face it: wouldn’t you rather use one site than dozens?

Screenshot of W3Schools page showing many of the topics

Let’s say, though, that you need information on CSS3. Well, you know that MDC covers CSS, so you return to the MDC site, and you click on the link that’s labeled “CSS”, and you look for something that says CSS3.

What do you mean there isn’t anything that says CSS3? What do you mean that transitions are CSS3—how am I, a CSS3 neophyte, supposed to know this?

Returning to W3Schools, I click the link in the main page that is labeled CSS3. Oh look, in the page that opens, there’s a sidebar link that’s labeled “CSS3 transitions”. And when I click that link, a page opens that provides an immediate example of using CSS3 transitions that I can try, as well as an easy to read table of browser support.

Screenshot of W3Schools CSS3 transitions page

W3Schools doesn’t throw a lot of text before the examples, primarily because we learn web material best by example. Remember that entire generations of web developers grew up with “View Source” as our primary learning tool.

But so far, I’ve only compared W3Schools to MDC. There are other useful sites that the W3Fools site approves. So I try the “Google: HTML, CSS, and JavaScript from the ground up” web page. When it opens, I click the link labeled CSS…

And I get a video about using CSS.

A video.

Remember in junior high or high school, when your science teacher would bring out the projector and you knew you were going to get a video? Do you remember that feeling that came over you? How you kind of relaxed, because you know the teacher wasn’t going to ask you any questions, and you didn’t have to write any notes, or even really pay attention?

I bet some of you even fell asleep during the video.

Videos are good for specific types of demonstrations—when something is complex, with many different steps, and the order of the steps and other factors have to be just so.

When it comes to CSS, HTML, and so many other web technologies, though, video is about the most passive and non-interactive learning experience there is. More importantly, if the video doesn’t have captioning, and most don’t, you’re also leaving part of your audience behind.

Now let’s return to the W3Schools site, this time looking at one of the CSS selector tutorials. The first thing you notice is that right below the example there’s a button, labeled “Try it Yourself”.

W3Schools screenshot showing the Try It button

Why read about it, when you can play?

One of the more annoying aspects of trying to learn about a specific HTML element, or a bit of CSS, is that you have to create an entire web page just to try it out. What W3Schools provides is that all important, absolutely essential, one button click to Try it out.

I’m not defending W3Schools. The site has played off the W3C title, though that doesn’t have a lot of meaning nowadays. More importantly, some of the material has errors and the site is resistant to correcting any of these errors, and this is unconscionable.

But you aren’t going to dent the popularity of the site without at least understanding why it is so popular. The W3Schools’ site is not popular because of SEO, and it’s not popular because of the W3 part of the name.

The W3Schools web site is so popular because it is so usable.

Categories
Burningbird Technology Weblogging

Another year, another web server

Drupal 7 is right around the corner, and my efforts to see how it would work on my existing server made me decide it is time to move to another hosting company. I need more control over my own space, and what is, or is not, installed. After discussions with the inestimable Laura Scott (@lauras), my go-to person for anything Drupal, I’ve decided on a Linode VPS account.

Linode has attracted a good Drupal community, which is important to me. In addition, it provides an extremely easy to use interface, which makes it quite simple to manage the space. I also like the fact that the company provides a good selection of documentation on how to do things geared to its own environment.

Since I’m making a major Drupal upgrade and moving to a new server, now is the time to look seriously at how my web sites are configured and designed, and make changes. I think this is one of the advantages to major releases—they provide a time to stop, think, and decide if you want to keep what you, or if now is the time to make all those other little changes you’ve been thinking about.

Since I’ve designed my own Drupal themes, I need to upgrade them to Drupal 7, as well as incorporate new HTML5/RDFa features. I may even do a re-design, not sure yet. I don’t like web site designing, so I may just grab one of the existing Drupal themes, and tweak it.

Several of my sites haven’t been updated in a donkey’s age, so I need to figure out if I’m going to continue writing at the sites. I probably will keep most, if not all, but I may do some major re-organizing.

I’ve not been taking many photos this year, as some of you have noticed. I need to re-design my photo pages to incorporate Drupal 7 changes and also my changed photography habits.

I’ve become much more interested in eBooks and the ePub format this last year. I was looking at creating an ePub module for Drupal, but someone already started this effort(Drupal ePub Module). However, there’s been little work on the module, and I’m thinking that an extension to the Print Module is a better approach. Or perhaps the best thing to do is just create an ePub friendly XHTML theme, and do a wget or curl on a book’s pages and use one of the many existing ePub publishing tools to create an ePub eBook. It’s better to be a smart developer than a clever one, and smart developers use what exists. Plus the same pages can be used to create a Kindle book, a Nook, and others.

I have been thinking of incorporating Disqus into some of my web sites. I’ve used this service at other sites, and I like how it works. Commenters can edit their comments, track their discussions across many sites, and they don’t have to provide a username and password for each web site (*cough* Gawker) to expose to hackers. Plus, if I turn comments off, the people still have access to their own writing. And Drupal has a module for Disqus, though I’ve not been able to get it to work with my theme (another reason to re-design my pages).

One thing I really like about Drupal 7 is if you don’t like the new administration interface, you can turn off all the new bits. You can turn off the overlay (don’t like), the page-top toolbar (still considering), and the new Dashboard (a keeper). I also like the fact that all the modules I use now are either incorporated directly into Drupal 7, or the developers have guaranteed a first day Drupal 7 release. Most of the modules have also committed to accessibility—that’s something you don’t often see with content management systems. Or W3C specifications.

Categories
Technology

That’s just not right

Earlier, I found a PR release from the AVMA (American Veterinarian Medical Association) undermining Missouri’s Proposition B in favor of its “model bill”. In an associated video, the AVMA’s CEO, Dr. DeHaven, states that Proposition B only sets limits on the number of dogs that can be kept, when in actuality, Proposition B does more (DeHaven’s video)—much more than the AVMA model bill, which relies almost completely on a commercial dog breeder honor system (and large scale commercial dog breeders are not necessarily known for their honor).

Afterward, I received an email related to a bug I’m following in the HTML5 working group. In response to detailed, thoughtful request for a way to provide alternative text for a video poster, the HTML5 editor, Ian Hickson, declined, writing as rationale:

The request here is just cargo-cult accessibility and would not
actually improve the life of any users, while costing authors in wasted time
and effort.

I reacted the same to both: that’s just not right.

You would think that humane treatment of dogs and ensuring accessibility for folks would be no-brainers, equivalent to being “agin sin”. You would think so…and you would be wrong.

Whatever sense of empathy and compassion we had, once upon a time, seems to have been left in a long ago forgotten consciousness. Today, what rules is the bottom line, and if that bottom line must run over the bodies of puppies and disabled, equally, run it must because there’s a new sense of pragmatic necessity that rules in the land.

Those who cannot see do not really need to know what the poster to a video is all about, because authors can’t really be bothered to provide the information. It’s not pragmatic to even consider the option. As Hickson stated earlier in the discussion of the bug:

I’m confused. Why would you (a blind user) want to know what the poster frame
is? How does it affect you?

How does it affect you‽

The welfare of dogs is important, yes, but not at the cost of the rights of the breeder. Weighing the needs of the dogs over the wants of the breeder is not pragmatic. The AVMA invited Wes Jamison, a communications professor from Florida, to speak about the role of veterinarians in today’s society. What he said explains much about the AVMA position:

Dr. Jamison … indicated that the veterinary profession, by emphasizing the importance of the human-animal bond, enables consumer hypocrisy, which is exploited by animal protection organizations. He argued that the AVMA should abandon advocating for the human-animal bond in favor of fighting for the right of animal owners to use animals as they choose, whether that entails companionship, food, or labor.

The human-animal bond is hypocrisy‽

Pragmatic hell, that’s just not right.