Brython - Python in the browser

Terry Reedy tjreedy at udel.edu
Wed Dec 19 21:46:49 EST 2012


On 12/19/2012 7:54 PM, Ian Kelly wrote:
> On Wed, Dec 19, 2012 at 5:07 PM, Terry Reedy <tjreedy at udel.edu> wrote:
>> That says that my browser, Firefox 17, does not support HTML5. Golly gee. I
>> don't think any browser support5 all of that moving target, and Gecko
>> apparently supports about as large a subset as most.
>> https://en.wikipedia.org/wiki/Comparison_of_layout_engines_%28HTML5%29
>> It is possible the FF still does not support the particular feature needed
>> for the clock, but then the page should say just that. Has the latest FF
>> (17) actually been tested?
>
> It works for me using FF 17.0.1.

It works for me too when ignore the mistaken and misleading error 
message and just turn on javascript for the page. Some sites say things 
like "You have javascript turned off. Turn it on to see all features."
>
>>> To create an element, for instance an HTML anchor :
>>> doc <= A('Python',href="http://www.python.org")
>>
>>
>> To me, that is a awful choice and I urge you to change it.
>
> +1.  The DOM already has a well-established API.  The following may
> require more typing:
>
> link = document.createElement('a')
> link.setAttribute("href", "http://www.python.org/")
> link.appendChild(document.createTextNode('Python'))
> document.body.appendChild(link)
>
> But it is much clearer in intent.

I agree with the rest of your suggestion.

-- 
Terry Jan Reedy




More information about the Python-list mailing list