Crow Canyon Software Forum

Forum Navigation
Please or Register to create posts and topics.

URLs in workflow emails

We have a scheduled workflow for a list that sends an email to each department head notifying them of unprocessed items in the list. There is a URL in the email that takes them to the items that need attention and that URL works okay as long as the WebApplication is hard-coded in the template, but if the email template is used in a different location, for instance our Development server, the URL points back to the records in our Production server rather than the ones in our Development server.

Normally in SharePoint, rather than using absolute URLs we use relative addresses by leaving the WebApplication portion off the URL, and SharePoint adds the correct information. For example, we would use this for the URL:
protocol://Production.server.com/Finance/Invoices/InBasket     (leave off the protocol://Production.server.com part)

and the result if copied our development server would be:
protocol://Development.server.local/Finance/Invoices/InBasket

SharePoint will usually make this change when saving the page/template, but not in this case. We've had a couple of close calls when we thought we were working on our Development server but were actually redirected back to the live Production server, which is not a good thing.

Email templates created with Custom Actions handle the URL addressing as expected and don't have this issue. Am I doing something wrong and is there a different way I can use a relative URL in a workflow email as expected by SharePoint? If not, would it be possible to have the workflow email templates behave the same as the custom action ones?

Hi,

URLs hardcoded in mail templates of Email Manager, Custom Actions and NITRO Workflows will point to the old URLs even if we use the same mail template in different web application.

To address this issue, we have added support for below placeholders in latest NITRO Studio pakage. Please use below placeholders to construct the URLs in mail templates.

Please let us know your SharePoint version (2013/2016/2019) and also the NITRO Studio version (Azure/Non-Azure) so that we will send the latest NITRO Studio package along with instructions.

1.[[SiteURL||SiteURL]]
2.[[SiteID||SiteID]]
3.[[SiteCollectionURL||SiteCollectionURL]]
4.[[SiteCollectionID||SiteCollectionID]]
5.[[ListURL||ListURL]]
6.[[ListID||ListID]

Thank you, you guys are awesome!