[Lon-capa-users] + signs (fwd)

Gerd Kortemeyer lon-capa-users@mail.lon-capa.org
Wed, 13 Feb 2002 21:05:11 -0500

This is a multi-part message in MIME format.
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit


You wrote:

> > Has there ever been a case where + signs get stripped from student
> > answers?????
> the .page handler is stripping submissions.
> Submitting the answer:
> !@#$%^&*()_+-={}[]|\:;"'<,>.?/
> to a .problem in a .page only
> !@#$%^
> Made it through to the homework handler.
Ahh ... so this only bombs if the .problem is in a .page?

I would guess that only the "&" and the "+" are goofed up. Your above string
gets chopped off after the "&" - you do not even get to the problem that Mark
had with the "+".

A normal form parameter submission is evaluated by splitting the input at the
"&" into its fields, and using "+" for spaces.

When the browser submits "!@#$%^&*()_+-={}[]|\:;"'<,>.?/", it does escape the
"&" and the "+" so that they are not mistaken for separators and spaces. When
LON-CAPA hits that form submission, it first detects the separator "&" and
space "+", and then unescapes the rest. So far, so good. And that is how far
it goes when you have a .problem outside a .page.

Now, lonpage does a lonnet::ssi with the re-distributed parameters. At this
point, I need to re-escape the parameters!!! I had wrongly assumed that LWP
would do that for me, but obviously, it does not. Aaarrghh.

>   Will you have time to look at this?
lonnet::ssi needs to be fixed. I am giving my midterms tomorrow and have an
ITR eval board guest. Will try.

Mark: sorry for this - I guess you will need to excuse or credit that problem.

- Gerd.

Content-Type: text/x-vcard; charset=us-ascii;
Content-Transfer-Encoding: 7bit
Content-Description: Card for Gerd Kortemeyer
Content-Disposition: attachment;

tel;fax:(517) 432-2175
tel;work:(517) 432-5468
title:Instructional Technology Specialist
adr;quoted-printable:;;123 North Kedzie Labs=0D=0AMichigan State University;East Lansing;MI;48824;USA
fn:Gerd Kortemeyer