TACTIC Open Source
How to get domain name from scripts? - Printable Version

+- TACTIC Open Source (http://forum.southpawtech.com)
+-- Forum: TACTIC Open Source (http://forum.southpawtech.com/forumdisplay.php?fid=3)
+--- Forum: TACTIC Discussion (http://forum.southpawtech.com/forumdisplay.php?fid=4)
+--- Thread: How to get domain name from scripts? (/showthread.php?tid=125)



How to get domain name from scripts? - listy - 05-30-2020

Hi!
When i am doing some custom notifications i use custom url's, but all my domain names are hardcoded.
I know there is a way to setup project config with domain name in it and choose it one, but may be there is another proper way?
Thanks!


RE: How to get domain name from scripts? - Celton McGrath - 05-30-2020

If you want to send notifications with links back to your TACTIC server, you can use the <services><mail_base_url/></services> directive.
Then the URL is available through the expression language variables BASE_URL and PROJECT_URL in the subject and messages attributes of the notification.

ie. Click <a href="{$PROJECT_URL}/link/my_tasks">here</a> to view your task.


RE: How to get domain name from scripts? - listy - 05-30-2020

Exactly what i needed, thanks!