Re: html sans html

On Wed, 21 Jan 2009, Dailey, David P. wrote:
>  
> a simple program to echo a user's input: 
> <script>n=prompt("hello"); alert(n)</script>
>
> Well, having seen a recent thread here about when <script> nodes run 
> (that have been inserted into the DOM) made me think of my experience in 
> class today: Opera, Firefox, Safari all responded to the above minipage 
> without complaint. Chrome accomplished what I thought it should have 
> (with a bit of harmless editorializing: it gave the user the option of 
> turning off the dialoguing; heck my students always have the option of 
> tuning me out, so why would this be any different?). IE on the other 
> hand was most ungracious, to my way of thinking, responding with a null 
> alert box, followed in short order by a "did you notice the information 
> bar" message asking if I would be so bold as to compromise the security 
> of the free world by enabling a possibly malicious script. Then, should 
> I be so bold, and after a few more steps, in which I enable scripted 
> windows, the script is then allowed to run ... alas.... incorrectly. If 
> the same page is run locally rather from a server then IE does not fuss 
> and the world is safe from discrete mathematics.
>
> I am pretty confident that IE6 didn't do this sort of thing, so I fear 
> it is one of many of modern browsers' attempts to hobble my 
> quirk-infested ways of teaching subjects using technology when chalk and 
> blackboards might be preferable. Does the spec address this and if so 
> whose browser is handling it correctly?

Per HTML5, all but IE seem to be handling this correctly. Browsers that 
allowed the script to be aborted while the dialogs were up get extra 
credit.

I don't understand IE's behavior... Is this an over-zealous popup blocker?

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Thursday, 22 January 2009 00:08:09 UTC