Project

General

Profile

Actions

Bug #27415

closed

ViewHelper Forms with method get and action parameter do not address to right action

Added by René Wagner almost 13 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Fluid
Target version:
-
Start date:
2011-06-13
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

A form like the following is rendered invalid:

<f:form action="list" method="get" id="searchForm" name="searchForm">...</f:form>

The reason is, it is addressing the action as a query string in the form action attribute. This query string gets completely substituted by the form fields inside the form.

Resolution: On get formulars, render the query string as hidden form fields.

Manual workaround:

<f:form action="list" method="get" id="searchForm" name="searchForm">
<f:form.hidden name="action" value="list" />
...
</f:form>

Actions #1

Updated by Stefan Neufeind almost 13 years ago

  • Status changed from New to Accepted
Actions #2

Updated by Stefan Neufeind almost 13 years ago

At least it would be up to the browser to merge the two (get-arguments from action-URL and from the form). I agree this doesn't seem right. And checking with at least Firefox 4 those arguments are lost as you describe.

Same holds true for fluid in FLOW3.

Actions #3

Updated by Bastian Waidelich almost 13 years ago

The way we should probably implement this, would be to create the action URI as before, parse it with parse_url() and retrieve the query parameters with parse_str() And then we could create the hidden fields from them. This should happen for GET only and it should be possible to deactivate it IMO.

Actions #4

Updated by Anja Leichsenring over 11 years ago

  • Project changed from 534 to 2559
  • Category changed from 963 to Fluid: ViewHelpers
Actions #5

Updated by Wouter Wolters about 11 years ago

TYPO3 Fluid has an implementation for this AFAICS

Actions #6

Updated by Clément MICHELET over 10 years ago

Seems to be fixed in Flow3 in issue #11636
Any hope to have backport for 6.2 ?

With this bug, I can't expect to have in working state in the same time :
  • a table with results
  • a filter form for table
  • a paginate widget

Pass hidden value didn't work with 6.1.5.
Set the form method to post imply to persist form values which is an alternative solution but imply also many new checks to handle.

Actions #7

Updated by Marc Bastian Heinrichs over 10 years ago

  • Target version set to Fluid 6.2

We could not backport this 1:1 because we have to have realurl in mind.

Actions #8

Updated by Alexander Opitz over 9 years ago

  • Project changed from 2559 to TYPO3 Core
  • Category changed from Fluid: ViewHelpers to Fluid
  • Target version changed from Fluid 6.2 to 7.0
  • TYPO3 Version set to 6.2
  • Is Regression set to No
Actions #9

Updated by Mathias Schreiber over 9 years ago

  • Target version changed from 7.0 to 7.1 (Cleanup)
Actions #10

Updated by Benni Mack almost 9 years ago

  • Target version changed from 7.1 (Cleanup) to 7.4 (Backend)
Actions #11

Updated by Susanne Moog over 8 years ago

  • Target version changed from 7.4 (Backend) to 7.5
Actions #12

Updated by Benni Mack over 8 years ago

  • Target version deleted (7.5)
Actions #13

Updated by Claus Due over 8 years ago

I suggest closing this one. It is known that creating colliding field names causes the last used field name to override others. That's very much by design, would also happen in a regular form where you set "action" with arguments you also set in form - and all the suggested acrobatics about parsing the current request seems to be much overkill. It's not really a "bug", it's more of a feature - that you're actually able to for example set a dynamic controller name, template format etc. by creating input fields named for these reserved API-level URL parameters.

Actions #14

Updated by Claus Due over 7 years ago

  • Status changed from Accepted to Closed

Closing, partly due to lack of interest (no activity in three years) and partly due to this being by design. If you disagree with the decision feel free to request reopening or open a new issue referring to this one.

Actions

Also available in: Atom PDF