W3C home > Mailing lists > Public > www-style@w3.org > September 1996

Right paren in urls

From: Jon Degenhardt <jrd@netcom.com>
Date: Sat, 07 Sep 1996 15:23:21 -0700
Message-ID: <3231F5D9.38C2@netcom.com>
To: www-style@w3.org
CC: jrd@netcom.com
A minor syntax question: What are the legal ways specify urls containing
parentheses? Right parentheses are "safe" characters in urls and don't
to encoded, but they are also the termination character in style sheet

My guess is that unencoded right parens would be legal in quoted urls,
illegal in unquoted urls. For example:

   Legal:    BODY { background: url("right)paren.gif") }
   Legal:    BODY { background: url('right)paren.gif') }
   Illegal:  BODY { background: url(right)paren.gif) }

However, this isn't clear to me from the style sheet specs. The lex
in Appendix B of 7/26/96 CSS-1 Working Draft doesn't handle any of these
This suggests all three forms may be illegal. The lex form from the
draft is:

   "url("[^\n)]+")"        {yylval.str = noquotes(yytext+3); return

This terminates the url at the first right paren, in a quoted string or

--Jon Degenhardt
  DocuMagix, Inc.
Received on Saturday, 7 September 1996 18:32:58 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:26:41 UTC