HTML 5

42 views
Skip to first unread message

philip

unread,
Jan 23, 2009, 5:59:43 PM1/23/09
to SWFObject
Hey Bobby and Geoff

Was just wondering what the plans are for handling HTML 5 now that
some bleeding-edge developers are starting to use it.

HTML 5 sites:

* An Event Apart (by Meyer & Zeldman http://aneventapart.com/)
* UX London (http://uxlondon.com/)
* Bruce Lawson (http://www.brucelawson.co.uk/)
* Anne van Kesteren (http://annevankesteren.nl/2009/01/moving-the-
goalposts)
* Sam Ruby (http://intertwingly.net/blog/)
* and others

(Links to more HTML 5 sites can be found at http://ishtml5readyyet.com/
and in Jeremy Keith's blog http://adactio.com/journal/1540)

How will HTML 5 affect SWFObject? I'm not really sure yet. One
observation I'd like to point out is that Anne's HTML 5 site has no
<head> or <body> elements. Is this valid HTML 5? Doesn't appear to
be (http://www.whatwg.org/specs/web-apps/current-work/multipage/
semantics.html).

But if it is, it will break SWFObject's createCSS method, which relies
on a <head> element.

I'm wondering what other aspects of the script might be affected, such
as valid attributes for <object> and how the domready event could be
affected.

I know it's hard to develop a solid JS library like SWFObject for a
specification that isn't even official yet, but if people are starting
to use HTML 5 in the real world, maybe we should look at supporting it
sooner rather than later.

Looking forward to the conversation. :)
- philip

Sam Sherlock

unread,
Jan 23, 2009, 8:30:34 PM1/23/09
to swfo...@googlegroups.com
I guess little if any changes will need to be made to swfobject for html5

  • swfobject is js referanced by the page
  • html5 still has ids - swfobject will still be able to use ids in the same way to replace content just as it currently does
I could well be wrong

2009/1/23 philip <plate...@gmail.com>

Geoff Stearns

unread,
Jan 24, 2009, 2:41:11 AM1/24/09
to swfo...@googlegroups.com

How will HTML 5 affect SWFObject?  I'm not really sure yet. One
observation I'd like to point out is that Anne's HTML 5 site has no
<head> or <body> elements.  Is this valid HTML 5?  Doesn't appear to
be (http://www.whatwg.org/specs/web-apps/current-work/multipage/
semantics.html
).

But if it is, it will break SWFObject's createCSS method, which relies
on a <head> element.

I'm wondering what other aspects of the script might be affected, such
as valid attributes for <object> and how the domready event could be
affected.

These are good questions - the main thing on my mind is whether or not something like SWFObject would even be needed... at least in an idea world we could all stop using it and the browser could do everything for us, but I think that's a whole lot of wishful thinking...

I do think that this should always be the end goal for us. Think of SWFObject as a temporary crutch util the world can catch up :)
 

I know it's hard to develop a solid JS library like SWFObject for a
specification that isn't even official yet, but if people are starting
to use HTML 5 in the real world, maybe we should look at supporting it
sooner rather than later.

I guess a first step is to check out the changes to how plugins are handled, and what, if any, changes there are to the object tag (and what the deal is with the embed tag, if it's around at all, etc.).

SWFObject is kinda like voodoo magic since we purposefully ignore standards in favor of supporting various corner cases, and I still think this is the appropriate solution going forward.

So, anyone want to do some light reading of the new spec and maybe make some test cases for us?

 

Bobby

unread,
Jan 24, 2009, 8:55:08 AM1/24/09
to SWFObject
No worries, HTML5 is on my radar for quite a while now. Although there
are already a few people who like to promote HTML5 (things are going
too slow for them I presume), and although most new web browsers will
trigger standards mode when reading the DOCTYPE, HTML 5 is still a
working draft and its new features are hardly supported cross-browser,
e.g.: http://crisp.tweakblogs.net/blog/434/using-the-html5-doctype-prematurely-considered-harmful.html

And it won't be much effort to make SWFObject fit this new standard in
the future, but let's keep things practical by all means and not go
ahead too much. Also, the createCSS method will not rely on the head
element anymore from SWFObject 2.2. onwards (see 2.2 dev notes).
Reply all
Reply to author
Forward
0 new messages