Afternoon all,

Fairly simple one this one but one that seems to be beyond me today. SharePoint 2007 survey that I'd like to redirect once the user hits finish. I have a custom Thankyou.aspx page for this.

As the SharePoint 2007 survey forms don't appear to allow me to add web parts or edit the pages, I've embedded a SharePoint form control into a Web Part Page to give me more options.

JQuery is an option as it's installed in my local environment and I only have access to SharePoint Designer 2007 and client side dev.

Any pointers appreciated.

1 Answer 1


The following solution is based on the redirection from the empty page inserted into the end of a Survey form.


  • Add Page Separator at the end of Survey list (see pic. below) in order to insert an additional empty page enter image description here
  • Embed the following JavaScript code into Survey edit form

Snippet: redirects from the last Survey page

function getParameterByName(name) {
    name = name.replace(/[\[]/, "\\[").replace(/[\]]/, "\\]");
    var regex = new RegExp("[\\?&]" + name + "=([^&#]*)"),
        results = regex.exec(location.search);
    return results == null ? "" : decodeURIComponent(results[1].replace(/\+/g, " "));

   var fieldName = getParameterByName('FirstField');
   if(fieldName == "ID"){
          window.location.href = "/pages/thankyou.aspx";

  • 1
    This'll need to be embedded via SPD I think. I'll put it in the PlaceHolder main and will test. Thanks for the snippet. Commented May 7, 2014 at 12:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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