Andrew Fedoniouk | 1 Dec 01:02 2006

[whatwg] HTML syntax: shortcuts for 'id' and 'class' attributes


While we are on the subject of discussing HTML syntax....

How about following (wild) idea?

To allow following notation (borrowed from CSS selectors):

<p.myclass>...</p> is equivalent of 
<p class="myclass">...</p> 

<p#myid>...</p> is equivalent of 
<p id="myid">...</p> 

<p.myclass1.myclass2>...</p> is equivalent of 
<p class="myclass1 myclass2">...</p> 

<p#myid.myclass1.myclass2>...</p> is equivalent of 
<p id="myid" class="myclass1 myclass2">...</p> 

It is syntax sugar of course but at least it will reduce amount of data 
needs to be sent over the wire.

Andrew Fedoniouk.
http://terrainformatica.com

Matthew Raymond | 1 Dec 03:40 2006
Picon
Picon

Re: [whatwg] HTML syntax: shortcuts for 'id' and 'class' attributes


Andrew Fedoniouk wrote:
> While we are on the subject of discussing HTML syntax....
> 
> How about following (wild) idea?
> 
> To allow following notation (borrowed from CSS selectors):
> 
> <p.myclass>...</p> is equivalent of 
> <p class="myclass">...</p> 
> 
> <p#myid>...</p> is equivalent of 
> <p id="myid">...</p> 
> 
> <p.myclass1.myclass2>...</p> is equivalent of 
> <p class="myclass1 myclass2">...</p> 
> 
> <p#myid.myclass1.myclass2>...</p> is equivalent of 
> <p id="myid" class="myclass1 myclass2">...</p> 
> 
> It is syntax sugar of course but at least it will reduce amount of data 
> needs to be sent over the wire.

   Okay, here's what's wrong:

1) Wrong mailing list.

2) Requires you to know two languages to write HTML instead of one.

3) It probably violates XML, so I'm guessing it can't be done in XHTML.
(Continue reading)

Boris Zbarsky | 1 Dec 04:11 2006
Picon

Re: [whatwg] HTML syntax: shortcuts for 'id' and 'class' attributes


Matthew Raymond wrote:
> 6) It would take thousands of elements with IDs and/or class names to
> make the savings in file size non-trivial. (You could save just as many
> characters per page by making the |alt| attribute optional on <img>
> elements.)

And even more to the point, you could save a lot more than this by using gzip 
content or transfer encoding.

-Boris

Ian Hickson | 1 Dec 04:27 2006
Picon

Re: [whatwg] HTML syntax: shortcuts for 'id' and 'class' attributes


On Thu, 30 Nov 2006, Andrew Fedoniouk wrote:
> 
> While we are on the subject of discussing HTML syntax....
> 
> How about following (wild) idea?
> 
> To allow following notation (borrowed from CSS selectors):
> 
> <p.myclass>...</p> is equivalent of 
> <p class="myclass">...</p> 
> 
> <p#myid>...</p> is equivalent of 
> <p id="myid">...</p> 
> 
> <p.myclass1.myclass2>...</p> is equivalent of 
> <p class="myclass1 myclass2">...</p> 
> 
> <p#myid.myclass1.myclass2>...</p> is equivalent of 
> <p id="myid" class="myclass1 myclass2">...</p> 
> 
> It is syntax sugar of course but at least it will reduce amount of data 
> needs to be sent over the wire.

Unfortuntely that wouldn't be backwards compatible, and so isn't really an 
option.

--

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
(Continue reading)

Andrew Fedoniouk | 1 Dec 05:46 2006

Re: [whatwg] HTML syntax: shortcuts for 'id' and 'class' attributes


----- Original Message ----- 
From: "Ian Hickson" <ian <at> hixie.ch>
>
> Unfortuntely that wouldn't be backwards compatible, and so isn't really an
> option.
>

Ian, what does this "backward compatibility" mean?

1) HTML5 is backward compatible with HTML4 so any HTML5 aware UA can read 
HTML4 files
without any additional setup. That implies HTML4 is a subset of HTML5.

-or -

2) Any HTML4 aware UA can render HTML5.  That is possible only if HTML5 is 
exactly HTML4 or its subset (but not superset).

What of these is true?

Andrew Fedoniouk.
http://terrainformatica.com

David Woolley | 1 Dec 08:04 2006
Picon
Picon

Re: [whatwg] HTML syntax: shortcuts for 'id' and 'class' attributes


[ OT - HTML not Style ]

> 2) Any HTML4 aware UA can render HTML5.  That is possible only if HTML5 is 
> exactly HTML4 or its subset (but not superset).

3) Competently written pages gracefully degrade to provide as much function
as possible on HTML 4 browsers, in particular on real life implementations
of HTML 4 browsers.  (Note, in many countries, if you provide a service to
the public, you may be legally required to go beyond this an provide all
the essential functionality, although you may be able to do that by linking
to alternative versions of the page.)

Robert Chapin | 1 Dec 03:37 2006

[CSS3UI] Concerned about Appearance:Password


In light of new attack vectors described at ...

http://www.info-svc.com/news/11-21-2006/

.... it is highly unlikely that an Appearance:Password property would be
implemented in a safe way.

My 2 cents
_____________
Robert Chapin
Chapin Information Services, Inc. 

Robert Chapin | 2 Dec 01:43 2006

[CSS3UI] Concerned about Appearance: Password


In light of new attack vectors, it is highly unlikely that an Appearance:
Password property would be implemented in a safe way.

My 2 cents
_____________
Robert Chapin
Chapin Information Services, Inc. 

David Woolley | 2 Dec 09:52 2006
Picon
Picon

Re: arguments and embedding


> 
> 
> i'm wondering if anything like the following is being looked at for future
> versions, or if anything similar already exists.

Variations on this are rejected at regular intervals.  You should search
the archives for details.

> I'm mainly wondering how all the current repetition in css is being

Heavy repetition in CSS generally indicates either that the styling
is capricious and doesn't reflect the structure, or simply a failure to
factor the CSS properly, by listing multiple selectors against a 
single rule.

More generally, this sort of macro processing can be done server side or
even in the authoring tool, without having to change the over the wire
format.

Bjoern Hoehrmann | 2 Dec 11:41 2006
Picon
Picon

Re: [CSS3UI] Concerned about Appearance:Password


* Robert Chapin wrote:
>In light of new attack vectors described at ...
>
>http://www.info-svc.com/news/11-21-2006/
>
>.... it is highly unlikely that an Appearance:Password property would be
>implemented in a safe way.

I don't see the relationship between the two, could you elaborate?
--

-- 
Björn Höhrmann · mailto:bjoern <at> hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 


Gmane