Priority: Normal
Current State: No Action Required
Released In: n/a
Target Release: patch
Applies To: Engine
Component: Edit.pm
Branches:
Steps to reproduce:
- Create an HTML form to create new topics (form action=http://foswiki.org/bin/edit). Add
formtemplate
with a topic name (and not Web.Topic), say SomeForm, and don't set templatetopic
- Define SomeForm in the current web (can't be System)
- Use the HTML form
- In the edit screen, the Form is empty and refers to SomeForm instead of SomeForm in the current web
IF the HTML form sets some templatetopic in the current web (and the topic exists), the error doesn't occurs.
I detected this after upgrading from 1.0.9 to 1.1.2 and trying to use existing HTML forms to create new topics and replace some forms on existing topics.
Proposed patch:
--- Edit.pm.orig 2011-02-18 11:26:21.000000000 -0300
+++ Edit.pm 2011-02-18 11:25:19.000000000 -0300
@@ -387,7 +387,7 @@
elsif ($form) {
my $formDef;
try {
- $formDef = new Foswiki::Form( $session, $templateWeb, $form );
+ $formDef = new Foswiki::Form( $session, $web, $form );
}
catch Foswiki::OopsException with {
@@ -398,7 +398,7 @@
# Reverse-engineer a form definition from the topic.
# Allow OopsException to propagate
$formDef =
- new Foswiki::Form( $session, $templateWeb, $form, $topicObject );
+ new Foswiki::Form( $session, $web, $form, $topicObject );
}
# Update with field values from the query
Suggestions?
--
GilmarSantosJr - 18 Feb 2011
I have no idea what you're talking about, but I'm sure you'll be clever enough to know whether your patch is good or not
--
OlivierRaginel - 21 Feb 2011
Changing the feedback requirement to Gilmar - I don't understand the change, but he seems to know what the problem is. Gilmar?
--
CrawfordCurrie - 27 Apr 2011
I
think this might fixed for 1.1.4 as a result of work on
Item10874 and
Item10446
--
PaulHarvey - 07 Jul 2011
I can't recreate the issue. Marking No Action.
--
GeorgeClark - 09 Jan 2015