<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.3.3" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: Virtual Subdomains and PHP</title>
	<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/</link>
	<description></description>
	<pubDate>Fri, 21 Nov 2008 21:24:43 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.3</generator>
		<item>
		<title>By: Fouad</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-171</link>
		<dc:creator>Fouad</dc:creator>
		<pubDate>Tue, 18 Nov 2008 10:04:28 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-171</guid>
		<description>Matt Hough... You Rock! Thanks!</description>
		<content:encoded><![CDATA[<p>Matt Hough&#8230; You Rock! Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matt Hough</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-157</link>
		<dc:creator>Matt Hough</dc:creator>
		<pubDate>Mon, 20 Oct 2008 16:02:05 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-157</guid>
		<description>oh, and I forgot, you can set up the root folder of it in the subdomain creation, where you will place your php file</description>
		<content:encoded><![CDATA[<p>oh, and I forgot, you can set up the root folder of it in the subdomain creation, where you will place your php file</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matt Hough</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-156</link>
		<dc:creator>Matt Hough</dc:creator>
		<pubDate>Mon, 20 Oct 2008 16:00:56 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-156</guid>
		<description>That is a long way round to do things. let me help you make life simpler in the future..

1. login to Cpanel
2. go to subdomains
3. create a subdomain with the name *  (example *.advtise.com)
4. all done!

and as for your php code, maybe helpfull for others to use:

$exp = explode(".", $_SERVER['HTTP_HOST']) ;
$username = $exp[0];

echo "you are username: ". $username;


Note $_SERVER

informative post, but no need when you can just do this way.</description>
		<content:encoded><![CDATA[<p>That is a long way round to do things. let me help you make life simpler in the future..</p>
<p>1. login to Cpanel<br />
2. go to subdomains<br />
3. create a subdomain with the name *  (example *.advtise.com)<br />
4. all done!</p>
<p>and as for your php code, maybe helpfull for others to use:</p>
<p>$exp = explode(&#8221;.&#8221;, $_SERVER[&#8217;HTTP_HOST&#8217;]) ;<br />
$username = $exp[0];</p>
<p>echo &#8220;you are username: &#8220;. $username;</p>
<p>Note $_SERVER</p>
<p>informative post, but no need when you can just do this way.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-126</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Fri, 22 Aug 2008 01:08:19 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-126</guid>
		<description>Hi,

Something happened to my virtual subdomains and they no longer work. Apache and probably the entire system and server software was upgraded. The site works, but my subdomains do not. The .htaccess file was missing after the upgrade. I copied up my backup, but any subdomain entered defaults to the Apache default page as if I just setup a new account. Again, the main page loads fine for the domain.

Any areas to look? PHP files have not been updated since Feb, March, or April of 2008. The only thing that has changed was an Apache and CPanel upgrade. Not sure about PHP and MySQL, but mod_rewrite works fine since I created a link1/link2 simple test.

Thanks,

Tom</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Something happened to my virtual subdomains and they no longer work. Apache and probably the entire system and server software was upgraded. The site works, but my subdomains do not. The .htaccess file was missing after the upgrade. I copied up my backup, but any subdomain entered defaults to the Apache default page as if I just setup a new account. Again, the main page loads fine for the domain.</p>
<p>Any areas to look? PHP files have not been updated since Feb, March, or April of 2008. The only thing that has changed was an Apache and CPanel upgrade. Not sure about PHP and MySQL, but mod_rewrite works fine since I created a link1/link2 simple test.</p>
<p>Thanks,</p>
<p>Tom</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mario</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-115</link>
		<dc:creator>Mario</dc:creator>
		<pubDate>Tue, 29 Jul 2008 19:55:39 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-115</guid>
		<description>I need this soooooooooooooo bad, I am gonna try it and if it works, I am buying you a drink!!</description>
		<content:encoded><![CDATA[<p>I need this soooooooooooooo bad, I am gonna try it and if it works, I am buying you a drink!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Shouvik</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-21</link>
		<dc:creator>Shouvik</dc:creator>
		<pubDate>Fri, 28 Sep 2007 09:44:57 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-21</guid>
		<description>Hello,

I was looking for such a tutorial for the past 1 week and this tutorial has actually solved my problem,


Thanx a lot for sharing this with us



God Bless
Shouvik</description>
		<content:encoded><![CDATA[<p>Hello,</p>
<p>I was looking for such a tutorial for the past 1 week and this tutorial has actually solved my problem,</p>
<p>Thanx a lot for sharing this with us</p>
<p>God Bless<br />
Shouvik</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mark Garbers</title>
		<link>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-20</link>
		<dc:creator>Mark Garbers</dc:creator>
		<pubDate>Wed, 03 Jan 2007 19:19:42 +0000</pubDate>
		<guid>http://www.decodephp.com/2006/10/12/virtual-subdomains-and-php/#comment-20</guid>
		<description>Hey there,
Thanks so much for this entry- I've spent hours trying to get this right and your post solved it in a few minutes!
I've used catch all subdomains on several sites of mine, but this is the first time that I've had to set them up myself.
Kind regards
Mark</description>
		<content:encoded><![CDATA[<p>Hey there,<br />
Thanks so much for this entry- I&#8217;ve spent hours trying to get this right and your post solved it in a few minutes!<br />
I&#8217;ve used catch all subdomains on several sites of mine, but this is the first time that I&#8217;ve had to set them up myself.<br />
Kind regards<br />
Mark</p>
]]></content:encoded>
	</item>
</channel>
</rss>
