i created a simple spaghetti code, wherein a user inputs data, then shall receive an email..my question is, how to include the url of the portal without having to hardcode it such as
http://www.test.com/index.php?activate=$test
that is, http://www.test.com <– this is all i want
is there a built-in function that i can use in order to be able to use the url of the portal and send the correct path to the recipient ?
Take a look at
$_SERVERglobal variable and its keys.