Re: [whatwg] Attribute for holding private data for scripting

2008-04-23 Thread Ian Hickson
On Sun, 8 Apr 2007, Henri Sivonen wrote: At http://www.quirksmode.org/blog/archives/2007/04/html_5.html PPK suggests having an attribute for storing private data for scripts. Currently, one can invent an attribute and it will work for scripts. However, it will look ugly for conformance

Re: [whatwg] Attribute for holding private data for scripting

2007-04-12 Thread Henri Sivonen
On Apr 12, 2007, at 01:45, Michael A. Puls II wrote: On 4/11/07, Henri Sivonen [EMAIL PROTECTED] wrote: I was thinking of establishing an attribute such as script-private where authors would be free to stick anything for retrieval by scripts. What would happen with embed

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Jonas Sicking
Here's a page I constructed, and tested on Firefox: http://intertwingly.net/stories/2007/04/10/test.html This page is meant to be served as application/xhtml+xml. Can you test it and see what results you get? Then lets discuss further. In Safari 2.0.4: Processed as HTML, it says data and

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread ryan
On Apr 9, 2007, at 10:27 AM, Maciej Stachowiak wrote: On Apr 8, 2007, at 11:12 AM, Henri Sivonen wrote: At http://www.quirksmode.org/blog/archives/2007/04/html_5.html PPK suggests having an attribute for storing private data for scripts. Currently, one can invent an attribute and it will

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Maciej Stachowiak
On Apr 10, 2007, at 11:42 PM, Jonas Sicking wrote: Here's a page I constructed, and tested on Firefox: http://intertwingly.net/stories/2007/04/10/test.html This page is meant to be served as application/xhtml+xml. Can you test it and see what results you get? Then lets discuss further.

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Sam Ruby
Maciej Stachowiak wrote: On Apr 10, 2007, at 8:12 PM, Sam Ruby wrote: Maciej Stachowiak wrote: On Apr 10, 2007, at 2:14 PM, Sam Ruby wrote: Anne van Kesteren wrote: On Tue, 10 Apr 2007 22:41:12 +0200, Sam Ruby [EMAIL PROTECTED] wrote: How so? I missed the part where you wanted to change

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Anne van Kesteren
On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Per HTML5 section 8.1.2.3, however, such an attribute name would not be considered conformant. Yes, only attributes defined in the specification are conformant. Despite this, later in document, in the description of

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Anne van Kesteren
On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: To give a specific example: say I make my own mjsml prefix with namespace http://example.org/mjsml;. In HTML4 UAs, to look up an mjsml:extension attribute using getAttribute(mjsml:extension). In HTML5 UAs, I'd have to

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Sam Ruby
Anne van Kesteren wrote: On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Per HTML5 section 8.1.2.3, however, such an attribute name would not be considered conformant. Yes, only attributes defined in the specification are conformant. I was specifically referring to

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Anne van Kesteren
On Wed, 11 Apr 2007 13:53:21 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Anne van Kesteren wrote: On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Per HTML5 section 8.1.2.3, however, such an attribute name would not be considered conformant. Yes, only attributes

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Sam Ruby
Anne van Kesteren wrote: On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: To give a specific example: say I make my own mjsml prefix with namespace http://example.org/mjsml;. In HTML4 UAs, to look up an mjsml:extension attribute using getAttribute(mjsml:extension). In

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Sam Ruby
Anne van Kesteren wrote: On Wed, 11 Apr 2007 13:53:21 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Anne van Kesteren wrote: On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Per HTML5 section 8.1.2.3, however, such an attribute name would not be considered conformant. Yes,

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Anne van Kesteren
On Wed, 11 Apr 2007 14:15:15 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Anne van Kesteren wrote: On Wed, 11 Apr 2007 13:40:39 +0200, Sam Ruby [EMAIL PROTECTED] wrote: To give a specific example: say I make my own mjsml prefix with namespace http://example.org/mjsml;. In HTML4 UAs, to look up

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Anne van Kesteren
On Wed, 11 Apr 2007 14:15:19 +0200, Sam Ruby [EMAIL PROTECTED] wrote: [...] Like others, I'm not convinced that the way forward is to allow a new attribute which has a micro-grammar for parsing what would be represented in the DOM essentially as a character blob. That's fine. I'm merely

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Jon Barnett
If you want structured data in this attribute, why not just use JSON? That's an idea that crossed my mind as well. I dismissed it for a few reasons: - authors would have to entitize quotes and ampersands in their attributes, which they're not used to doing with JSON normally. - evaluating it

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Sam Ruby
Anne van Kesteren wrote: I think I'd rather have something simple such as prefix_name for extensions made by ECMAScript libraries, etc. (As opposed to an in scope xmlns:prefix=http://...; with prefix:name extensions which work differently in XML.) That would also work better for element

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Dean Edwards
Kristof Zelechovski wrote: (as client side Lisp is my personal dream) http://www.cs.stevens.edu/~dlong/software/kamen/index.php -dean

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Kevin Marks
On 4/11/07, Jon Barnett [EMAIL PROTECTED] wrote: If you want structured data in this attribute, why not just use JSON? That's an idea that crossed my mind as well. I dismissed it for a few reasons: - authors would have to entitize quotes and ampersands in their attributes, which they're not

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Kevin Marks
On 4/11/07, Jon Barnett [EMAIL PROTECTED] wrote: On 4/11/07, Kevin Marks [EMAIL PROTECTED] wrote: On 4/11/07, Jon Barnett [EMAIL PROTECTED] wrote: If you want structured data in this attribute, why not just use JSON? That's an idea that crossed my mind as well. I dismissed it for a

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Henri Sivonen
On Apr 11, 2007, at 16:04, Sam Ruby wrote: 1) re: prefix_name - how are prefixes registered? Henri is free to correct me if I am wrong, but I gathered that the requirement was for a bit of decentralized extensibility, i.e., the notion that anybody for any reason could defined an extension

Re: [whatwg] Attribute for holding private data for scripting

2007-04-11 Thread Maciej Stachowiak
On Apr 11, 2007, at 6:04 AM, Sam Ruby wrote: Anne van Kesteren wrote: I think I'd rather have something simple such as prefix_name for extensions made by ECMAScript libraries, etc. (As opposed to an in scope xmlns:prefix=http://...; with prefix:name extensions which work differently in

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Simon Pieters
On Mon, 09 Apr 2007 21:37:31 +0200, Jon Barnett [EMAIL PROTECTED] wrote: I can think of two possibilities. One would be to allow the param element as a child of any element (or any block level element?) http://www.whatwg.org/specs/web-apps/current-work/#param And then make an attribute of

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Sam Ruby
On 4/10/07, Simon Pieters [EMAIL PROTECTED] wrote: Or allow any attribute that starts with x_ or something (to prevent clashing with future revisions of HTML), as private attributes. Instead of starts with x_, how about contains a colon? A conformance checker could ensure that there is a

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Anne van Kesteren
On Tue, 10 Apr 2007 20:21:27 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Or allow any attribute that starts with x_ or something (to prevent clashing with future revisions of HTML), as private attributes. Instead of starts with x_, how about contains a colon? A conformance checker could ensure

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Jon Barnett
On 4/10/07, Sam Ruby [EMAIL PROTECTED] wrote: Instead of starts with x_, how about contains a colon? A conformance checker could ensure that there is a corresponding xmlns declaration that applies here, and possibly even do additional verification if it recognizes the namespace. An HTML5

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Sam Ruby
On 4/10/07, Anne van Kesteren [EMAIL PROTECTED] wrote: On Tue, 10 Apr 2007 20:21:27 +0200, Sam Ruby [EMAIL PROTECTED] wrote: Or allow any attribute that starts with x_ or something (to prevent clashing with future revisions of HTML), as private attributes. Instead of starts with x_, how

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Anne van Kesteren
On Tue, 10 Apr 2007 22:41:12 +0200, Sam Ruby [EMAIL PROTECTED] wrote: How so? I missed the part where you wanted to change existing HTML parsers. I thought Hixie pointed out earlier (by means of examples) why we can't have namespace parsing in HTML. I suppose we can discuss it again...

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Sam Ruby
Anne van Kesteren wrote: On Tue, 10 Apr 2007 22:41:12 +0200, Sam Ruby [EMAIL PROTECTED] wrote: How so? I missed the part where you wanted to change existing HTML parsers. I thought Hixie pointed out earlier (by means of examples) why we can't have namespace parsing in HTML. I suppose we can

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Anne van Kesteren
On Tue, 10 Apr 2007 23:14:16 +0200, Sam Ruby [EMAIL PROTECTED] wrote: I missed the part where you wanted to change existing HTML parsers. I thought Hixie pointed out earlier (by means of examples) why we can't have namespace parsing in HTML. I suppose we can discuss it again... It is a

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Maciej Stachowiak
On Apr 10, 2007, at 2:14 PM, Sam Ruby wrote: Anne van Kesteren wrote: On Tue, 10 Apr 2007 22:41:12 +0200, Sam Ruby [EMAIL PROTECTED] wrote: How so? I missed the part where you wanted to change existing HTML parsers. I thought Hixie pointed out earlier (by means of examples) why we can't

Re: [whatwg] Attribute for holding private data for scripting

2007-04-10 Thread Sam Ruby
Maciej Stachowiak wrote: On Apr 10, 2007, at 2:14 PM, Sam Ruby wrote: Anne van Kesteren wrote: On Tue, 10 Apr 2007 22:41:12 +0200, Sam Ruby [EMAIL PROTECTED] wrote: How so? I missed the part where you wanted to change existing HTML parsers. I thought Hixie pointed out earlier (by means of

Re: [whatwg] Attribute for holding private data for scripting

2007-04-09 Thread Maciej Stachowiak
On Apr 8, 2007, at 11:12 AM, Henri Sivonen wrote: At http://www.quirksmode.org/blog/archives/2007/04/html_5.html PPK suggests having an attribute for storing private data for scripts. Currently, one can invent an attribute and it will work for scripts. However, it will look ugly for

Re: [whatwg] Attribute for holding private data for scripting

2007-04-09 Thread ddailey
Henri, thanks for the link to PPK's suggestions -- I rather like many of them. Henri Sivonen wrote: At http://www.quirksmode.org/blog/archives/2007/04/html_5.html PPK suggests having an attribute for storing private data for scripts. I'm having a hard time seeing what you're talking about

Re: [whatwg] Attribute for holding private data for scripting

2007-04-09 Thread Jon Barnett
I can think of two possibilities. One would be to allow the param element as a child of any element (or any block level element?) http://www.whatwg.org/specs/web-apps/current-work/#param And then make an attribute of HTMLElement called params readonly attribute HTMLCollection params; Where

[whatwg] Attribute for holding private data for scripting

2007-04-08 Thread Henri Sivonen
At http://www.quirksmode.org/blog/archives/2007/04/html_5.html PPK suggests having an attribute for storing private data for scripts. Currently, one can invent an attribute and it will work for scripts. However, it will look ugly for conformance checking. Since this is essentially a