The default bug view has changed. See this FAQ.

submission 'post' to file doesn't work

RESOLVED FIXED

Status

Core Graveyard
XForms
RESOLVED FIXED
11 years ago
9 months ago

People

(Reporter: aaronr, Assigned: aaronr)

Tracking

({fixed1.8.0.12, fixed1.8.1.4})

Trunk
x86
All
fixed1.8.0.12, fixed1.8.1.4

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments, 1 obsolete attachment)

1.99 KB, application/xhtml+xml
Details
7.62 KB, patch
Doron Rosenberg (IBM)
: review+
Details | Diff | Splinter Review
(Assignee)

Description

11 years ago
If the form author specifies submission with @method="post" but uses a @action that is a local file, then we'll generate a xforms-submit-error.  This is because we assume that if the method type is post that the channel will be a nsIHttpChannel and bow out if it isn't.  Since other xforms processors don't generate an error with this scenario, I assume we are behaving incorrectly?

I talked to Jonas about it and he didn't think that there would be a security problem or anything if we treated POST like GET for all other protocols other than HTTP, which seems to be what XSmiles and formsPlayer do.

So should we do that or should we do the submission error like we do now and just put a better error in the Error Console?
(Assignee)

Comment 1

11 years ago
Created attachment 243416 [details]
testcase
(Assignee)

Comment 2

10 years ago
started a thread in the WG mailing list (http://lists.w3.org/Archives/Public/www-forms/2007Feb/0086.html).  Looks like it is non-normative (per Leigh's reply), so we can basically do what we like.  Unless we get some more feedback from the thread, I'd say we adopt formsPlayer's and XSmile's stance for replace="all" at least.  But should we continue to throw an error on replace="instance"?

Comment 3

10 years ago
Might give this one a day or two to see if anybody disagrees with me.
(Assignee)

Comment 4

10 years ago
Created attachment 255950 [details] [diff] [review]
patch
Attachment #255950 - Flags: review?(Olli.Pettay)
(Assignee)

Comment 5

10 years ago
Comment on attachment 255950 [details] [diff] [review]
patch

fixing bug by allowing "post" with file protocol when replace="all" or "none".  We'll put a warning in the error console for all other non-http protocols and when file is used with replace="instance".  And in the warning cases, a xforms-submit-error event will still be sent as happened before this patch.
Attachment #255950 - Flags: review?(doronr)
Comment on attachment 255950 [details] [diff] [review]
patch



>+  if (mFormat & METHOD_POST)
>+  {

if (mFormat & METHOD_POST) {
Attachment #255950 - Flags: review?(Olli.Pettay) → review+
(Assignee)

Comment 7

10 years ago
Created attachment 255955 [details] [diff] [review]
patch2

fixes smaug's comment
Attachment #255955 - Flags: review?(doronr)
(Assignee)

Updated

10 years ago
Attachment #255950 - Attachment is obsolete: true
Attachment #255950 - Flags: review?(doronr)

Updated

10 years ago
Attachment #255955 - Flags: review?(doronr) → review+
(Assignee)

Comment 8

10 years ago
checked into trunk
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → FIXED
Whiteboard: xf-to-branch
(Assignee)

Comment 9

10 years ago
checked into 1.8 branch on 2007-04-12
checked into 1.8.0 branch on 2007-04-16
Keywords: fixed1.8.0.12, fixed1.8.1.4
Whiteboard: xf-to-branch
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.