Hiding content for image replacement

One of the most valuable tools in a web designers arsenal is the ability to replace text with images, of course in a graceful way. That technique is exactly what makes the CSS Zen Garden layouts work. Thanks to NickFitz we now know the right way to do this (and why the wrong way may sometimes be right). Read his excellent article Why “left: -9999px;” is Better For Accessibility Than “display: none;”.

From 4 to 5; a seismic shift in HTML

Further to my thoughts a few months back on the propsed specification for HTML5 (it was even commented on by a genuine web heavyweight). Well, the whole issue isn’t going away so I thought I’d bring my measly mind to bear on this fascinating subject again.

First, a quick explanation. I say “fascinating” because this is potentially one of the biggest shake-ups on the web in (10?) years. While new versions of browsers is noteworty, making large changes to the language that those browsers actually speak natively is a massive shift. Just think, in a couple of years time we could be marking up our documents with “aside”‘s, “dialog”‘s and “figure”‘s. That, dear readers, is a Big Thing.

The reason this has come to the fore again is because Anne Van Kesteren has written an easy-to-understand document outlining the differences between HTML5 and HTML4. As she states, most of the HTML5 specification isn’t about adding new things, but fixing the old things so they can be used in a standard way across user agents.

Still, it’s the new stuff that excites us geeks most of all. Here’s a few of my favourites which I didn’t make a note of last time (and maybe my feelings on this have changed in the last 4 months).

event-source can be used to “catch” server sent events”

Wow, so there’s going to be an actual element specifically for that AJAX stuff? Cool.

output represents some type of output, such as from a calculation done through scripting”

Ditto what I said above. This is good news, as despite my best intentions pages with a lot of JavaScript working on them always end up looking like a dogs dinner. Semanticise and control, I say.

And then this one is, as our American friends would say, a doozy:

The input element’s type attribute now has the following new values:

  • datetime
  • datetime-local
  • date
  • month
  • week
  • time
  • number
  • range
  • email
  • url

The idea of these new types is that the user agent can provide the user interface, such as a calendar date picker or integration with the user’s address book and submit a defined format to the server. It gives the user a better experience as his input is checked before sending it to the server meaning there is less time to wait for feedback.

Now that would be useful. Inbuilt browser input validation. I’ll raise a glass to that.

Anyway, take a look at the document. What bits are you most interested in?

As time goes by

It’s been all quiet on the blogging front recently, not least because last week I celebrated my thirtieth birthday. Most people, even those that know me quite well, can’t believe I’ve only just reached 30 as obviously I look a lot older than that. And having seven children between my wife and I tends to make me seem older.

By “celebrated” I mean I went to church. No just any church, but my good friend Dawn’s new church (she’s one of these new-fangled women vicars). They don’t seem to have a website at the moment for the church itself, but they also run a project called Urban Space (although this might tell you more about them). It all looks very exciting.

The other reason why I’ve been so busy is the amount of work I have at the moment. Don’t get me wrong, it’s all good enjoyable stuff, but I do feel like I need a holiday. So it’s fantastic that the wife bought us tickets for Greenbelt, which says about itself:

Greenbelt is an independent Christian charity working to express love, creativity and justice in the arts and contemporary culture in the light of the Christian gospel.

But if you want to call it a lefty, tree-hugging Christian arts and music festival that’s alright with me. I haven’t been able to go for the last few years, so it will be a nice return. Not only will it be chance to meet up with a lot of old friends, but it will be Reubens for taste of a festival (even if we are spending the nights in a hotel).

As ever I’ll be an optimist and say I’ll be back blogging regularly about geek stuff soon, but in all likelihood it will remain as sporadic as ever.

Big business, big attitude

I felt this dubious exchange (hat tip) was worth highlighting, not just because it’s a prime example of how NOT to interact with your customers, but because the rest of Andrews blog is so interesting. One for the feed reader, methinks.

And speaking of interacting with customers the wrong way, I’ve got a cautionary tale to tell you soon about a company I deal with. However I’ll wait for them to pay me the money they owe me (no, I’m not holding my breath) before I spill the beans. Trust me, this is a masterclass in bad P.R.