E-Mail a Link issue in SharePoint 2007

When I use the “Send to >> E-Mail a Link” in SharePoint 2007, it gave me the wrong link!!!

E-Mail a Link issue in SharePoint 2007

It created a link like this one: https://mysite%2Ecom/test/agenda.doc, But it should be: https://mysite.com/test/agenda.doc

Notice how the server name is URL encoded too. The %2E’s should be periods.

To fix this: we need to edit the core.js file located at C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\LAYOUTS\1033 (Make a backup copy of this file before you make changes)

Find this line:
fileUrl=escapeProperly(httpRootWithSlash.substr(0, slashLoc))+currentItemUrl;

and replace it with this:
fileUrl=httpRootWithSlash.substr(0, slashLoc)+currentItemUrl;

We need to do the same on all the SharePoint WFE and Application servers. Once done, we will need to do IISRESET on all the above servers.

Salaudeen Rajack

Salaudeen Rajack - Information Technology Expert with Two-decades of hands-on experience, specializing in SharePoint, PowerShell, Microsoft 365, and related products. He has held various positions including SharePoint Architect, Administrator, Developer and consultant, has helped many organizations to implement and optimize SharePoint solutions. Known for his deep technical expertise, He's passionate about sharing the knowledge and insights to help others, through the real-world articles!

Leave a Reply

Your email address will not be published. Required fields are marked *