Developer forum

Forum » CMS - Standard features » Forms for editors - post URL

Forms for editors - post URL

René Poulsen
René Poulsen
Reply

Hi,

On an ecommerce solution I'm using the form for editors module on a productpage using snippets. When the form is submitted I would like to stay on the same product as I was before the form was submitted. Lets say I'm on domain.dk/default.aspx?id=20&productid=prod10. When I submit the form right now, I'm redirected to domain.dk/default.aspx?id=20&s=XM9YqBOEVUM%3d. So now I do not know which product to show = I show nothing. Is it possible for the forms for editors to submit to the current page - INLCUDING all url parameters?


Replies

 
Nicolai Pedersen
Reply

Hi René

This should work (untested though)

On the form, create 2 hidden fields using the forms module. One named "formSubmitAction" with the value of "page" and one called "formSubmitPageAfterSave" with the url to redirect to. So like this

<input type="hidden" name="formSubmitAction" value="page">
<input type="hidden" name="formSubmitPageAfterSave" value="default.aspx?id=20&productid=prod10">

The first field just needs the value static from the module. The second field you have to fill using js or something else.

Hope it will work.

BR Nicolai

 
René Poulsen
René Poulsen
Reply

Hi Nicolai,

Doesn't seem to work. I've attached a screenshot with the module on the paragraph - and with the html it outputs.
Both fields are created on the form in the module. I just get redirected to the same page with - only with ID + S url parameter: Default.aspx?ID=2561&s=xYQwAvt3%2bDQ%3d

rt.jpg
 
René Poulsen
René Poulsen
Reply

Bump

 
René Poulsen
René Poulsen
Reply

Bump bump :-)

 
René Poulsen
René Poulsen
Reply

Is this supposed to work or not? Or do I need to be on a specific DW version for it to work? I'm on 8.6.1.7.

 
Nicolai Pedersen
Reply
This post has been marked as an answer

Yes, that is a problem. It seems to have been implemented in 8.7.0.1

Votes for this answer: 1

 

You must be logged in to post in the forum