cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mac Schwarz <mcsch...@phil.uni-erlangen.de>
Subject XSP form processing
Date Fri, 18 Aug 2000 15:22:37 GMT
Hi,

I've got a problem building forms with xsp and just can't figure out how
to do it correctly at the moment. 
I'm just running in circles I think and need an 'eureka effect'.

We want to build some exercises for a language learning project. One
type of exercises would be a gaptext e.g.

<gaptext>
In this sentence a <gab id="1">word</gap> ist missing. Complete these
two <gap id="2>sentences</gap> with the correct words.</gaptext>

Now I need to build a xsl file to transform the gaptext into a form with
the two gaps as input fields (without the words enclosed with the
<gap>-tags of course) and a submit button below. After submission of the
form it should be evaluated (the words inserted by the students compared
with the corresponding words of the source text above) and the text
shown again with the correct answers filled in the text fields of the
form and the wrong answers displayed as empty text fields for another
attempt. Or a page with congratulations for passing the test :-)

I tested variants of the xsp example and code snippets I found in the
mailing list archives, but without avail. Since I don't know the number
of gaps in the text beforehand I can't define the parameters with
<xsl:param> at the top of the stylesheet. So I think I need xsp. I don't
want to use the GET method also to avoid URL encoded parameters but all
of my experiments working with GET never showed any key-value pairs
after changing the method to POST.

I took a look at the fp taglib also and noticed it's potential for a
great range of but for this particular problem I don't think it's
suitable.

I would be grateful for any example code for form processing with xsp. 

Regards,
	mac

-- 
Mac Schwarz / AERIA Projekt / Inst. f. Klassische Archaeologie
e-mail: mac@aeria.phil.uni-erlangen.de  / Tel.: 09131-85-24791
 FAU Erlangen-Nuernberg   /   Kochstr.4   /   91054 Erlangen
  <http://www.phil.uni-erlangen.de/~p1altar/aeriahome.html>

Mime
View raw message