On 2 Aug 2001, ap wrote:

> Thank you for the quick reply and the version 2.21! I installed it,
> but semicolons still don't work. I looked a little at the ASP.pm code
> and compared the version 0.09 to version 2.21. I may be completely
> wrong, but it looked to me that in version 0.09, you used the method
> parse_params in the CGI.pm module to parse the query string, while in
> 2.21, the ASP.pm method ParseParams is used. Parse_params in CGI.pm
> does a split(/[&;]/,$tosplit), while ParseParams in ASP.pm does a
> split /\&/, $string, -1. Could this be the difference?

Probably, although I haven't actually looked at the code so I'm just going
by what you're saying.

You could change the split statement in your copy of ASP.pm and the
semicolon will work.

> Anyway, this is not a "show stopper" for me, and I wouldn't want you
> to feel the need to change something that might break something else.
> I just have a faint memory of having read somewhere that semicolons
> were preferable to ampersands when delimiting query string paramaters,
> which is why I used them in the first place.

Using ampersands in delimiting query string parameters is technically
invalid HTML, because & is used to denote special characters like <,
>, ", etc.

If you run a document that has ampersands in the query string through
validator.w3.org, it will complain at you. Also, if your variables happen
to be called "copy", "amp", "quot" etc. (anything that is a named special
character that goes after &) unexpected messups can occur.

There's two "correct" ways of writing query strings:

1. Use & instead of &

2. Use ; instead of & (assuming your query string parser supports it)


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to