-
How can I tell what was entered?
Question....
How can I get php to tell me if a user types in the www part in their browser of if they just type in the domain mydomain.com
Examples: Users type in..
www.mydomain.com/this_directory/this_file.php
mydomain.com/this_directory/this_file.php
http://www.mydomain.com/this_directory/this_file.php
www.mydomain.com
mydomain.com
]I don't care about the http:// I also don't care about the /this_directory/this_file.php
I ONLY want to know if the user typed in either www OR mydomain.com OR www.mydomain.com How can I get php to tell me this?
Please help, please?
-Thanks!
-
Use the superglobal; $_SERVER['SERVER_NAME']
Do you know how to use strpos or preg_match to find one string in another string?
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
|
Bookmarks