Getting Subdomain Name With PHP?


Posted on 16th Feb 2014 07:03 pm by admin

I want to grab the subdomain name with PHP so I can generate database queries.

for example my subdomain is san-jose.mydomain.com

Did you know?Explore Trending and Topic pages for more stories like this.
How would I go about grabbing the subdoman name with PHP? Thanks!
No comments posted yet

Your Answer:

Login to answer
256 Like 46 Dislike
Previous forums Next forums
Other forums

php redirecting
i wont open a new thread but i have a question about redirecting....
i wonder why my code doesnt

Javascript form submit and radio buttons?
When this form is submitted, it is automatically resubmitted using JS.

All my fields are carr

Error with Font and imagettfbbox
I keep getting an error that says "Warning: imagettfbbox() [function.imagettfbbox]: Could not f

Move array index to end
Hey guys,
Quick question:

I have an array that looks like this:
Code: [Select]$var =

BAPI BBP_INB_DELIVERY_CREATE - material number missing in delivery
Hi Experts,

I was able to successfully create an Inbound delivery with reference to a PO

error checking breaking my code
Hi there, OK first of all, big apologies for what I assume is really fundamental errors in the struc

Protecting forms
Alright, I want to protect some forms of mine from SQL Injections, because I had someone earlier spa

Dynamically allocating the number of rows in a table based on a variable value
Hi,
I have situation here which i cannot resolve, I have a variable temp which stores the num

PHP Captcha Error help - replace the "die" command
Hi All,

I am after a bit of help with a Captcha spam protection box.

The site gave me

Add a sign-up feature to a flat file login script
I'm working on a flat file login script and I would like to add a sign-up feature to it with a email

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash