[css-url-selector] Proposal for a new selector

Hi,

This is my first post to this mailing list so hopefully I am doing
things correctly here.

The css-url-selector would work as follows:
-Checking the URL of the document in the same way than the
 Attribute Selector
 (http://www.w3.org/TR/css3-selectors/#attribute-selectors)

-According to the Location Interface
 (http://www.w3.org/TR/Window/#location)

Consider the following URL
http://www.example.com:80/europe.htm?year=2012#results

The protocol -> http
The hostname -> www.example.com
The pathname -> /europe.htm
The search   -> ?year=2012
The hash -> #results

Examples:

@url( href*="europe" )
{
    /*rules*/
}
@url( protocol="https" )
{
    /*rules*/
}
@url( host*="example.com" )
{
    /*rules*/
}
@url( hostname$=".com" )
{
    /*rules*/
}
@url( port^="8" )
{
    /*rules*/
}
@url( pathname$=".htm" )
{
    /*rules*/
}
@url( search*="year" )
{
    /*rules*/
}
@url( hash$="results" )
{
    /*rules*/
}

Thanks for your time.

Regards,
Omar Vigon

Received on Thursday, 2 May 2013 17:18:40 UTC