-
Type:
Bug
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 7.0.X, 7.1.X, 7.2.X, Master
-
Fix Version/s: 7.0.0 DXP FP89, 7.0.10.13 DXP SP13, 7.0.X, 7.1.10 DXP FP16, 7.1.X, 7.2.10 DXP FP2, 7.2.10.1 DXP SP1, 7.2.X, 7.2.1 CE GA2, 7.3.10 DXP GA1, Master
-
Component/s: Forms
-
Branch Version/s:7.2.x, 7.1.x, 7.0.x
-
Backported to Branch:Committed
-
Fix Priority:3
-
Git Pull Request:
Description
When a valid “Redirect URL on Success” is configured the form does not redirect and instead a “No value is defined for field..” error is seen in the UI. Though the form does successfully get submitted.
Steps to reproduce
- Set redirect.url.domains.allowed to blank (which is the default) and redirect.url.security.mode=domain on portal.properties (so as to allow redirecting from Liferay to external domains)
- Create a form with any required field (e.g. text field);
- In the form setting set the "Redirect URL on Success" to a valid known URL;
- Save the form
- Add the form to a page
- Fill the required form field and submit
Results of Testing
Expected Result: The form will be submitted and the user will be redirected to the success page;
Actual Result: The form will be submitted, but the user won't be redirected on success. An error message will appear saying "No value is defined for field..."
Errors/Logs
Depending on the affected version, a different result will appear, but the redirection won't happen.
In Chrome one can see the following error
Access to XMLHttpRequest at 'https://www.liferay.com/pt/home' (redirected from 'http://localhost:8080/web/guest/home?p_p_id=com_liferay_dynamic_data_lists_form_web_portlet_DDLFormPortlet_INSTANCE_SX1f83rcniGM&p_p_lifecycle=1&p_p_state=normal&p_p_mode=view&_com_liferay_dynamic_data_lists_form_web_portlet_DDLFormPortlet_INSTANCE_SX1f83rcniGM_javax.portlet.action=addRecord&p_auth=DV8WSRNi') from origin 'http://localhost:8080' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.
Reproduced on
master git hash 8f3351359c0f27823a8798a2077a2b2a26e0dad0
7.2.x git hash 05b89e58b929443db5c12191766f6cad16a18cee
7.1.x git hash bedf729391ee066dbb3c94cce2faf187665fcbf4
7.0.x git hash ad9d60faf581bde658667f7058f285b0ce70fa63