Priority: Urgent
Current State: Closed
Released In: n/a
Target Release: n/a
Applies To: Extension
Component: FormPlugin
Branches: trunk
With a standard form using the
FormPlugin it is not possible to submit the form using IE 7.0.5730.13 while it is no problem with Firefox. The error message is
You have a form element calles 'submit' that conflicts with the form.submit function. Rename the element to make the form work. The TML code of the form is:
<verbatim style="display: none;">
%TMPL:DEF{PROMPT:box_shedule}%
<div class="foswikiFormSteps">
<div class="foswikiFormStep">
%STARTFORM{
name="box_shedule"
action="save"
method="POST"
topic="%WEB%.BoxScheduleData"
strictverification="off"
}%
<input type="hidden" name="comment_action" value="save" />
<input type="hidden" name="comment_type" value="box_shedule" />
<input type="hidden" name="comment_templatetopic" value="%WEB%.%TOPIC%" />
%FORMELEMENT{
name="Who"
type="text"
title="Who:"
validate="nonempty"
default="%WIKINAME%"
mandatory="on"
hint="User name"
}%
%FORMELEMENT{
name="Date"
type="date"
dateformat="%d %b %Y"
size="9"
title="Date:"
disabled="%IF{"$WIKINAME='WikiGuest'" then="on" else="off"}%"
validate="nonempty"
}%
%FORMELEMENT{
name="Box"
type="radio"
title="Which box to work on"
options="Little Box=old/little box (the one besides the window),Big Box=new/big box (the one besides the door)"
validate="nonempty"
}%
%FORMELEMENT{
name="Initials"
type="hidden"
readonly="on"
value="%INITIALS%"
}%
%FORMELEMENT{
name="action"
type="submit"
buttonlabel="Add my date"
disabled="%IF{"WIKINAME='WikiGuest'" then="on" else="off"}%"
}% %IF{"$WIKINAME='WikiGuest'" then="<em>$percntRED$percntLog in to add your dates$percntENDCOLOR$percnt</em>"}%
%ENDFORM%
</div>
</div>
%TMPL:END%
%TMPL:DEF{OUTPUT:box_shedule}% * %URLPARAM{"Date"}% - %URLPARAM{"Box"}% - %URLPARAM{"Who"}% - %CALC{$CHAR($CODE(%FORMFIELD{"FirstName" topic="Main.%URLPARAM{"Who"}%"}%))}%%CALC{$CHAR($CODE(%FORMFIELD{"LastName" topic="Main.%URLPARAM{"Who"}%"}%))}%
%POS:AFTER%%TMPL:END%
</verbatim>
---+++ New Entry
%NOTE% A hidden list is used as a database for the BoxSchedule. Just fill the form for entering new entries or modify the bullet list by hand (System.HolidaylistPlugin will give you advice).
%TIP% Editing of existing entries can be done in the topic [[http://%HTTP_HOST%/Indris/BoxScheduleData?noredirect=on][BoxScheduleData]]. A second entry for one day and box won't be displayed, so the first person planing to use a box is responsible for coordinating the others.
%<nop>COMMENT{type="box_shedule" noform="on" templatetopic="%WEB%.%TOPIC%" target="%WEB%.BoxScheduleData"}%
%HOLIDAYLIST{startdate="-1" enablepubholidays="1" showweekends="1" tcwidth="33px" topic="%WEB%.BoxScheduleData"}%
The
FormPlugin version is 2.2.0, $Rev: 12318 (2011-08-14) $ and the
CommentPlugin version is 10 Apr 2011, $Rev: 11361 (2011-04-10) $
--
HolgerHain - 26 Oct 2011
Normally you get this error if the submit button (or any other field of that form) is called "submit". I cannot find that in the code however, so I am not sure what is happening.
A possibility it that it is related to the fix of 2.2.1: "24 Aug 2011 2.2.1 Use different default name for submit field that does not have a name set.". So could you see if a newer version fixes your problem?
--
ArthurClemens - 16 Dec 2011
Meantime we have the plugin version 2.2.3 and it still does not work. And it is only a problem to internet explorer (just checked version 7.0.5730.13). With firefox everything works fine.
I also renamed the submit-fields of the jump- and the search-form of the top bar.
I further checked the html source code without finding any formelement that is called "submit". Every form field with type
submit
is actually called "action".
--
HolgerHain - 19 Dec 2011
Confirmed. IE7 does that. But IE* as well. Now I'll find out why.
Somehow javascript always returns 'Object' in IE7/8. I've changed it to another function (use jquery attribute selector).
--
ArthurClemens - 20 Dec 2011