ZDNet UK


Skip to Main Content

ZDNet.co.uk - Winner of Best Business Website 2007
  1. Home
  2. News
  3. Blogs
  4. Reviews
  5. Prices
  6. Resources
  7. Community
  8. My ZDNet

 

ZDNet UK RSS Feeds


IT Jobs

Application development Toolkit

W3C's latest standard: Scripting's swansong?

Paul Festa CNET News.com CNET News.com

Published: 10 Jan 2003 11:53 GMT

  • Email
  • Trackback
  • Clip Link
  • Print friendly
  • Post Comment

The Web's leading standards body released a long-delayed recommendation for using scripts in Web pages but urged coders not to rely too heavily on scripting.

The World Wide Web Consortium (W3C) recommended on Thursday its Document Object Model (DOM) Level 2 HTML, a module of the group's set of application programming interfaces (APIs) for letting computer languages like JavaScript, Java or ECMAScript manipulate elements in an HTML or XHTML document.

In practical terms, the DOM makes it easier to create Web pages with features that are more animated and functional. With scripts, authors can make Web pages process forms, launch pop-up menus and windows, and execute style changes on the fly. Without the DOM, authors would have to code separately for each scripting language to interact with each different browser. The DOM is meant to create a "write once, run everywhere" standard for Web page scripting.

However, W3C staff urged developers to use scripts sparingly, criticising the development technique as less efficient and accessible than alternative W3C-recommended methods of creating dynamic Web pages.

"The W3C is working on other specifications, including SVG, SMIL, and XForms, to move some commonly desired behaviours out of scripts," said Ian Jacobs, a W3C editor. "Scripting has its limitations."

The trouble with scripts, Jacobs said, is that they are less machine-readable or transparent than so-called declarative languages like SVG and SMIL.

"Scripts tend to do useful things, but in a way that's not obvious for machines to understand," Jacobs said. "I don't imagine a world where you could do everything in a nonscripting way, but it's very hard to know exactly what a script does. From the accessibility perspective, if everything is buried in a scripting language, then it's hard to find an alternative presentation of information. It's hard to repurpose the content."

Others at the W3C echoed Jacobs' attitude toward scripting and the DOM.

"Use the DOM the least you can," said Philippe Le Hégaret, the W3C's DOM activity lead. "If you have an alternative technique to do exactly what you want without using the DOM, then use it. This technology will be more accessible, and it will be easier for someone else to read it."

The DOM has been in progress at the W3C for more than five years. Level 1 came out in 1998, while most of Level 2 came out two years later, in November 2000.

But the part of Level 2 that specified how scripts could interact with HTML content -- as opposed to XML, for example, or style sheets -- had such serious bugs that it did not receive the W3C's recommendation until Thursday.

The DOM Level 2 is incompatible with Level 1 and consigns it to the recommendation trash heap, the W3C said.

The W3C "strongly suggests that developers and authors conform to DOM Level 2 HTML," the consortium wrote in its release.

The group, in concert with the United States National Institute of Standards and Technology (NIST), also updated its free test suite that developers can use to check their adherence to the standard.


ZDNet UK's Developer News Section delivers the latest headlines together with the best UK jobs, right to your browser.

Let the editors know what you think in the Mailroom.

  • Email
  • Trackback
  • Clip Link
  • Print friendly Print with Dell

Did you find this article useful?
71 out of 131 people found this useful


Full Talkback thread

0 comments


Company/Topic Alerts

Create a new alert from the list below:







Related Jobs

SOFTWARE ENGINEER (UNIX SHELL SCRIPTING, SQL)- Cambridge, South East

The Role: The primary responsibilities include: - Design, development and maintenance of new modules, enhancements and scripts for the ...

Senior Level Windows Engineer/Architect (Design,Build,AD,Scripting)

The candidate will be providing 3rd line engineering & support, hardware/software evaluation, automation using scripts & projects. Ideal candidates ...

Internet Team Leader

Good working knowledge of scripting languages i.e. To assist with the production of test plans, test scripts and the conduct of tests. Responsibility ...

Discussions

harpless harpless

SAP goes big business

Friday 25 July 2008, 6:17 PM

1 comment
pjc158 pjc158

Will Drizzle rain on Sun's MySql

Friday 25 July 2008, 5:30 PM

1 comment

Featured Talkback

The fact is: Software developers today are really designers and not coders. The reason that business anlaysts exist today to model solutions is because they understand the value of designing software before writing it. All too often developers create code that has little value because they do not understand that business classes interact with other classes within the confines of a working model or pattern.

By: 1000165269

Read full story:
Making sense of agile modelling