| |||||||
| Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics. |
![]() |
| | LinkBack | Thread Tools |
| | #1 (permalink) |
| Awesome™ | Detecting Domain Hey. I'm making a PHP script which will be distributed to many people. Long story short, I need the PHP script to be able to detect the domain name it's hosted on. I don't know how to go about doing this. It would be appreciated if someone could point me in the right direction of how this could be done. Thx in advance. |
| |
| | #3 (permalink) |
| Awesome™ | Well I'm not going to be fully in control of who gets this software, but I have a licensing system where I will keep track of who has it. I'm not sure you fully understand what I need. I need the domain on which the script is hosted. So for example, if the script is on http://thesite.com/script/directory/, I need the script to extract the "thesite.com" part. |
| |
| | #4 (permalink) |
| Senior Member | $_SERVER['HTTP_HOST'] will get the hostname. http://us3.php.net/reserved.variablesDo you need to get it remotely, or? |
| |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Redemption Grace Period | TopNames.com | Domain Newbies | 1 | 07-31-2007 11:04 AM |
| PPC Domain Manager Script Now Available! | Cyphix | Scripts For Sale | 8 | 04-01-2005 01:50 AM |
| Class Action Settlement Against Register.com | IAmAllanShore | Domain Name Discussion | 8 | 03-01-2005 02:13 PM |