You need to sign in to do that
Don't have an account?
oleg.tuchscherer
URLFOR(..) in conjunction with CUSTOM DOMAIN and managed package
Hi,
i have installed a managed package in a Sandbox and in the Live Org.
"My Domain" is configured.
An Email Template contains a formula, computing a link: {!SUBSTITUTE(URLFOR('/apex/VFPage'),'http:','https:')}
Linkg points to a Visualforce Page.
Visualforce Page is a part of managed package.
SANDBOX: url created by the formula in the sandbox is correct
------------------------------------------------------------------------------------------------
https://factory42--sb42--sf42-prfxpe.cs17.visual.force.com/apex/VFPage
LIVE: url is wrong
------------------------------------------------------------------------------------------------
https://factory42--c.eu3.visual.force.com/apex/VFPage
As you can see the the namespace prefix (sf42-prfxpe) is missed. Instead of prefix a '--c.' appears in the url.
The correct url looks as the following:
https://factory42--sf42-prfxpe.eu3.visual.force.com/apex/VFPage
Any ideas to get formula working in the live org?
Thanks in advance!
i have installed a managed package in a Sandbox and in the Live Org.
"My Domain" is configured.
An Email Template contains a formula, computing a link: {!SUBSTITUTE(URLFOR('/apex/VFPage'),'http:','https:')}
Linkg points to a Visualforce Page.
Visualforce Page is a part of managed package.
SANDBOX: url created by the formula in the sandbox is correct
------------------------------------------------------------------------------------------------
https://factory42--sb42--sf42-prfxpe.cs17.visual.force.com/apex/VFPage
LIVE: url is wrong
------------------------------------------------------------------------------------------------
https://factory42--c.eu3.visual.force.com/apex/VFPage
As you can see the the namespace prefix (sf42-prfxpe) is missed. Instead of prefix a '--c.' appears in the url.
The correct url looks as the following:
https://factory42--sf42-prfxpe.eu3.visual.force.com/apex/VFPage
Any ideas to get formula working in the live org?
Thanks in advance!
or does it redirect you to https://factory42--sf42-prfxpe.eu3.visual.force.com/apex/VFPage?
thx
The message "page VFPage does not exist" appears.
In your other code, does URLFOR work for your organization or all?
Try a simple VFpage below call it URLFORTEST and see if it redirect to you the account page or does not redirect you to "factory42--c" and error out.
thx.
then change URLFORTEST to to see if it direct you to the VFPage :
URLFOR works fine in VF pages.
How to get it working in email template?
https://factory42--sf42-prfxpe.eu3.visual.force.com/apex/......
You can put this string in a variable if you want, but dont use relation path.
Thx