W3C home > Mailing lists > Public > public-html@w3.org > June 2011

Re: Should script execution be allowed in designMode documents?

From: Simon Pieters <simonp@opera.com>
Date: Thu, 30 Jun 2011 10:10:42 +0200
To: "HTML WG" <public-html@w3.org>, "Boris Zbarsky" <bzbarsky@mit.edu>
Message-ID: <op.vxvqb41kidj3kv@simon-pieterss-macbook.local>
On Thu, 30 Jun 2011 04:38:55 +0200, Boris Zbarsky <bzbarsky@mit.edu> wrote:

> Forwarding this along for one of my coworkers who can't figure out how  
> to actually get on this list:
> Firefox has historically disabled script execution when a document is
> put into design mode by setting the designMode property on the
> document object to "on".  This has been done a long time ago to be
> compatible with IE.  But it has consistently surprised web developers.
>   Moreover, script execution has never been prevented in Firefox for
> contentEditable sections, which means that the result of putting a
> document in design mode and setting the contentEditable attribute on
> the body element will not be the same, which goes against the HTML5
> spec.
> Currently, Firefox, Safari and IE have this behavior, and Chrome and
> Opera allow script execution in design mode.  We're looking into
> lifting this restriction, and we would like to see what other
> implementers think about this issue.

Opera has had restrictions here and still does (from a quick test <script>  
blocks don't execute in Opera after having having turned on designMode),  
trying to be compatible with IE and Firefox and what Web applications  
expect. IE and Firefox are slightly different. Previously we found IE's  
model saner than Firefox's model, and implemented something close to IE's  
behavior, until it broke some Web app and we lifted a few restrictions. I  
don't recall the details exactly, but my point is that Opera has spent  
time reverse engineering and tweaking this area, and it's very hard to get  

I wouldn't be against following Chrome here.

Simon Pieters
Opera Software
Received on Thursday, 30 June 2011 08:10:51 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 29 October 2015 10:16:14 UTC