Hi Guys,
I've been using xwiki for a while now, but have only "recently" started
using v2 syntax.
In v1 a trick I'd often use in apps was to have a nested <FORM> element to
allow me to add some pre-filled objects to a page. Something like this:
#set ($list = ["Problem", "Feature", "Question"])
<FORM>
<SELECT name="field1"> #foreach ($item in $list) <OPTION
value="$item">$item</OPTION> #end </SELECT>
<INPUT type="submit" name="add" value="add" />
</FORM>
Then you could just catch and use the selection:
#if ($request.getParameter("add"))
$doc.newObject("someclass").set("Field1",
$request.getParameter("field1"))
$doc.save()
Obviously I've taken some shortcuts here.
This approach fails to work in inline mode for some reason. My form
definition seems to become subsumed by the overall form on the page now.
So is there some way for me to declare that I want my form outside of the
normal structure?
Or is there some smarter way of approaching this problem?
Thanks in advance.
Cheers,
Adam