Search code examples
http-redirectsharepoint-2010

How to Redirecting to source url from form (where submit or close the form)


On our main intranet page (homepage) http://indi.cdc.com I created a link to InfoPath form that is on a site collection http://indi.cdc.com/salesteam. So the link looks like this. When user click Submit or Cancel they are not redirected back to homepage (http://indi.cdc.com). They are seeing "The form has been closed.). Please suggest.

I tried following and neither is doing the redirection.

http://indi.cdc.com/salesteam/Lists/RequestsList/Issue/newifs.aspx?Source=http://indi.cdc.com/Pages/Home.aspx

http://indi.cdc.com/salesteam/Lists/RequestsList/Issue/newifs.aspx?Source=http://indi.cdc.com/Pages/Home.aspx?target=http://indi.cdc.com/salesteam

Solution

    1. Created a redirect page (http://indi.cdc.com/salesteam/SharedDocuments/Redirecting.html)

    2. Created a view on the target list where the InfoPath form is redirect.aspx, edit the page and dropped a CEWP and reference above html file from it. (http://indi.cdc.com/salesteam/spteam/Lists/RequestsList/redirect.aspx)

    3. Recreated the link on the homepage.

    http://indi.cdc.com/salesteam/spteam/Lists/RequestsList/Issue/newifs.aspx?Source=http://indi.cdc.com/salesteam/Lists/RequestsList/redirecting.aspx

    Here is the html code for redirecting.html page

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xmlns:mso="urn:schemas-microsoft-com:office:office" xmlns:msdt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882">
    
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    
    <meta http-equiv="Refresh" 
     content="0; URL=http://indi.cdc.com">
     <title></title>
    </head>
    
    <body>
    
    </body>
    
    </html>