If you have converted some or all of your organization’s paper forms into SharePoint forms (i.e. not an InfoPath form but the data entry form that is generated by a SharePoint list or library), there may be times when you want to link to one of these from a SharePoint links list. For example, a popularly-used form like a time-off request or help desk ticket could have a link on your portal’s home page.
The problem is that the URL for a SharePoint form is very long, and can surpass the character-length limit in the URL field of a Links list. We have seen a consistent issue where linking to a form from a cut-off URL will take the user to the desired form, but then produce a page error when they click OK or Cancel.
The simple workaround is to link to the list itself and teach the users to click the New button; however this isn’t the most user-friendly option. You could try creating a smaller link at www.tinyurl.com, but this won’t work well if the link is for an https:// environment.
If you have access to IIS then there is an easy way to create your own Tiny URLs as you like, plus they will work over https.
How? You would configure the IIS virtual server for the SharePoint Web Application and create virtual directories with redirection.
For example, you create a Virtual directory named TinyURL to store all the virtual directories used for TinyURL in your application. Under this you will start creating virtual directories with redirection to the long and complex URL inside SharePoint. Now instead of using the long URL you can type just the short one, e.g. https://sharepoint/TinyUrl/Link1
1. On your SharePoint web server, open IIS.
2. Expand to the current web site.
3. Right-click the current web site and choose New -> Virtual Directory
4. The wizard will pop up; click Next
5. In the Alias field, type your desired name (e.g. TinyUrl), and click Next
6. In the Path field, you need to choose an empty directory. You can create this anywhere, but I recommend the path:
[drive]\InetPub\wwwroot\wss\virtualdirectories\[your site]\ – browse to this, click Make New Folder, then enter [your desired folder name]
7. Click OK, then click Next
8. Accept the default permission, Read, and click Next, then Finish.
9. This creates the root folder for your tiny URLs.
Now we can add the URLs.
10. On the TinyURL virtual folder you just created, right-click and choose New -> Virtual Directory. Follow the steps shown above to go through the wizard; this time for the alias field enter your first link name (i.e. Link1) and the same path as before. We will create the redirection in the next step.
11. After you click Finish, right-click on the folder name you just created (Link1), and choose Properties.
12. Choose “A redirection to a URL,” enter your very long link name in the Redirect to: field, and then select “A permanent redirection for this resource,” as shown below:
Note: If you have multiple Web Front End Servers in your farm you will need to configure this for all of them and all the settings need to match.
Another approach would be to create a custom http module for the redirection and deploy this as a solution, but it will require code.
For people with a MOSS and publishing enabled there is a page named RedirectPage.aspx that can be created inside a page library. This can only be used for one URL per page, and the end-user has to visit the page in order to see the redirect link. This would be useful at times when you want the user to be aware of the redirection, for example from a discontinued website to a newly-released replacement.