This question about Using an extension: Answered
With the following code that uses
FormPlugin, the
PatternSkin is broken
This is a test
%STARTFORM{
name="myform"
action="view"
}%%FORMELEMENT{
name="Name"
type="text"
title="Enter your name:"
mandatory="on"
}%%FORMELEMENT{
type="submit"
buttonlabel="Submit"
}%
%ENDFORM%
There are at least two problems:
- The left bar is pushed to the right
- The edit button is obstructed and became inaccessible
Sometime it will back to normal after a few refresh (both IE8 and Firefox 3.5.1). I compared the raw HTML between the normal one and the problem one. I found the following code segment was not found when the problem occurred.
<!--GENERATED_HEADERS--><!-- FormPlugin --> <style type="text/css" media="all">
@import url("http://itvmsb01/foswiki/pub/System/FormPlugin/formplugin.css");
</style>
<script type="text/javascript" src="http://itvmsb01/foswiki/pub/System/JavascriptFiles/foswikilib.js"></script>
<script type="text/javascript" src="http://itvmsb01/foswiki/pub/System/JavascriptFiles/foswikiCSS.js"></script>
<script type="text/javascript" src="http://itvmsb01/foswiki/pub/System/JavascriptFiles/foswikiForm.js"></script>
<script type="text/javascript" src="http://itvmsb01/foswiki/pub/System/JavascriptFiles/foswikiString.js"></script>
--
HackatonWong - 18 Aug 2009
I cannot duplicate this. But if that HTML is sometimes not written to the page, it must be a serverside problem, not a frontend issue.
Why this happens is totally unclear to me.
--
ArthurClemens - 18 Aug 2009
It looks like a server side issue indeed! After switching back from mod_perl to plaint old CGI, the problem is gone. Might related to
http://foswiki.org/Tasks/Item8103
My server environment
Too bad both mod_perl and
FromPlugin are great!
--
HackatonWong - 19 Aug 2009
Closing this ticket due to inactivity. Please re-open it, if necessary.
--
OliverKrueger - 09 Oct 2009
Just now I have noticed the same problem. After some code inspection I have found a lonely closing DIV element generated by the ENDFORM macro:
</div><!--/FormPlugin form end-->
Well that's the Point. That DIV has never been opened, so it causes a layout crash. I suppose the STARTFORM macro should opened one but never did it. Quick workaround: Open a DIV by yourself (tip: surrounded by sticky tags). I hope that fixes your bug too.
--
SvenHess - 08 Feb 2010
Please download version 2 of FormPlugin. With the above code it generates this HTML:
<form method="post" action="foswiki/core/bin/view/Sandbox/FormPluginTest2#FormPluginNotification" enctype="multipart/form-data" name="myform" onsubmit="StrikeOne.submit(this)"><input type="hidden" name="validation_key" value="?f26cf8e0f99b70bacbdbe2b013a206ee">
<input type="hidden" name="FP_actionurl" value="foswiki/core/bin/view/Sandbox/FormPluginTest2">
<input type="hidden" name="FP_name" value="myform">
<div><div class="formPluginField"> <a name="FormElementMyformName"><!--//--></a> <span class="formPluginTitle">Enter your name:</span> <br> <input type="text" name="Name" tabindex="1" size="40" class="foswikiInputField"> <span class="formPluginMandatory">*</span> </div><div class="formPluginField"> <a name="FormElementMyformSubmit"><!--//--></a> <input type="submit" tabindex="2" name="submit" value="Submit" class="foswikiSubmit"> </div>
</div>
</form>
So no missing div in
STARTFORM
.
--
ArthurClemens - 31 May 2011