+ Start a Discussion

Is there a way to retrieve the current instance from the URL without using Apex

Hello All,
   I am currently using VF Email templates to send out a mail (using workflow) on creation of an Account. The email should also have a logo embedded. As per the below article static resources cannot be used and we should upload the logo into the Documents object.


In the last line of the above article, it is shown how the image should be referred to in the VF Email template.Some values need to be dynamically populated such as:  https://c.<instance>.content........
How can I get the current instance from the URL without using Apex? (I am not using any controllers). Is there a way to get that value (like cs6,na11, etc.) during rum time? I just need 'cs6' or 'na11' and not the complete URL.

I used a function in a formula field to fetch the value:  LEFT($Api.Partner_Server_URL_320, FIND( '/services', $Api.Partner_Server_URL_320)) but this returns https://cs6.salesforce.com