I have a script in which I need to get the domain of the site the script is running on into a variable in PHP so for example if someone uploads the script to their site - www.domain.com - the variable $domain in the PHP script needs to be set to the http://www.domain.com. Hope that makes sense.
I've looked in to using $_SESSION but I can't find a variable that retrieves just the domain. If anyone could help I'd be really greatful.
look into the $_SERVER command. if u run <?php phpinfo(); ?> on ur site, u can see what output the domain name. then jsut use that command with the server variable. ex. $_SERVER['HTTP_REFERR_AGENT']; or something along those lines. PM me and I can give ya the actual code when I get home and have access to my manuals and sources.