I have a custom list and I am showing some items on the home page. When the user clicks on a link it is sent to the display page. But, when you are on the display page, the cancel button returns the user to the list itself. I would like to redirect user back to the home page.

I know for save button there is a function called PreSaveAction(), but is there one for cancel button?


You will need to add Source Parameter in the query string.

For eg: If your link is:


Then with Source Parameter your link will be:


This will redirect to the home page.

For reference: Passing a Source Parameter on the Query String with Multiple Other Parameters

  • i had forgotten that completely. Thanks. It helped. – Burre Ifort Oct 13 '15 at 11:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.