<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: 8 useful server variables available in PHP</title>
	<atom:link href="http://roshanbh.com.np/2008/05/useful-server-variables-php.html/feed" rel="self" type="application/rss+xml" />
	<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html</link>
	<description>Useful Tutorials, Scripts , Tips, and Resources for all PHP and Ajax beginners and experts .</description>
	<lastBuildDate>Wed, 10 Mar 2010 10:59:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: goyal</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-5152</link>
		<dc:creator>goyal</dc:creator>
		<pubDate>Sat, 13 Feb 2010 06:26:44 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-5152</guid>
		<description>i am making a website, which will translate webpages in different lanaguages. the url of the served page will be as follows: http://www.bbgoyal.com/hi/index.php. in the above example, i dont wish to captute http://www.bbgoyal.com/hi/. tell me how to capture the remaining part?</description>
		<content:encoded><![CDATA[<p>i am making a website, which will translate webpages in different lanaguages. the url of the served page will be as follows: <a href="http://www.bbgoyal.com/hi/index.php" rel="nofollow">http://www.bbgoyal.com/hi/index.php</a>. in the above example, i dont wish to captute <a href="http://www.bbgoyal.com/hi/" rel="nofollow">http://www.bbgoyal.com/hi/</a>. tell me how to capture the remaining part?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: chiladelphia</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-4685</link>
		<dc:creator>chiladelphia</dc:creator>
		<pubDate>Tue, 13 Oct 2009 18:33:43 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-4685</guid>
		<description>echo $_SERVER[&quot;SERVER_NAME&quot;].$_SERVER[&quot;REQUEST_URI&quot;] doesn&#039;t return any javascript variables that i&#039;ve tacked on... bummer. 

any idea how i can get the #tabview=tab1</description>
		<content:encoded><![CDATA[<p>echo $_SERVER["SERVER_NAME"].$_SERVER["REQUEST_URI"] doesn&#8217;t return any javascript variables that i&#8217;ve tacked on&#8230; bummer. </p>
<p>any idea how i can get the #tabview=tab1</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pakistani</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-3590</link>
		<dc:creator>Pakistani</dc:creator>
		<pubDate>Sat, 21 Feb 2009 11:22:12 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-3590</guid>
		<description>I studied the all 8 variables. but i need to track the previous page so dynamically i should know the root. thanks you can help me on mjaved.khan@gmail.com</description>
		<content:encoded><![CDATA[<p>I studied the all 8 variables. but i need to track the previous page so dynamically i should know the root. thanks you can help me on <a href="mailto:mjaved.khan@gmail.com">mjaved.khan@gmail.com</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-3541</link>
		<dc:creator>John</dc:creator>
		<pubDate>Tue, 10 Feb 2009 15:55:52 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-3541</guid>
		<description>Here&#039;s a tip.

Write for the user instead of the search engines. All that first paragraph said to me was &#039;php, server variables, server, php, variable, server&#039;. For Christ&#039;s sake we know what you&#039;re talking about, PHP &amp; Server Variables.</description>
		<content:encoded><![CDATA[<p>Here&#8217;s a tip.</p>
<p>Write for the user instead of the search engines. All that first paragraph said to me was &#8216;php, server variables, server, php, variable, server&#8217;. For Christ&#8217;s sake we know what you&#8217;re talking about, PHP &amp; Server Variables.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Prevent form post request from another domain in PHP</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-1256</link>
		<dc:creator>Prevent form post request from another domain in PHP</dc:creator>
		<pubDate>Sun, 22 Jun 2008 09:54:03 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-1256</guid>
		<description>[...] time, I&#8217;ve posted the article about useful server variables in PHP. Among them, we can use HTTP_REFERRER server variables to prevent the cross domain form post [...]</description>
		<content:encoded><![CDATA[<p>[...] time, I&#8217;ve posted the article about useful server variables in PHP. Among them, we can use HTTP_REFERRER server variables to prevent the cross domain form post [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Variables del servidor útiles en PHP : Notitodo</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-880</link>
		<dc:creator>Variables del servidor útiles en PHP : Notitodo</dc:creator>
		<pubDate>Fri, 16 May 2008 11:24:16 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-880</guid>
		<description>[...] 8 useful server variables available in PHP [...]</description>
		<content:encoded><![CDATA[<p>[...] 8 useful server variables available in PHP [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daily Find #68 &#124; TechToolBlog</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-873</link>
		<dc:creator>Daily Find #68 &#124; TechToolBlog</dc:creator>
		<pubDate>Thu, 15 May 2008 12:50:22 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-873</guid>
		<description>[...] 8 useful server variables available in PHP - If you do PHP you probably already know these. [...]</description>
		<content:encoded><![CDATA[<p>[...] 8 useful server variables available in PHP &#8211; If you do PHP you probably already know these. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 8 ??????? ???????????? ????????? ?????????? ? PHP &#124; ????????.??</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-869</link>
		<dc:creator>8 ??????? ???????????? ????????? ?????????? ? PHP &#124; ????????.??</dc:creator>
		<pubDate>Wed, 14 May 2008 23:20:32 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-869</guid>
		<description>[...] ????????: ???? ?????? ????????. [...]</description>
		<content:encoded><![CDATA[<p>[...] ????????: ???? ?????? ????????. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Roshan</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-862</link>
		<dc:creator>Roshan</dc:creator>
		<pubDate>Wed, 14 May 2008 11:13:42 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-862</guid>
		<description>I know document_root sucks in shared hosting...you can know more about these from here as well..

http://roshanbh.com.np/2008/01/absolute-path-and-relative-path-file-inclusion-in-php.html</description>
		<content:encoded><![CDATA[<p>I know document_root sucks in shared hosting&#8230;you can know more about these from here as well..</p>
<p><a href="http://roshanbh.com.np/2008/01/absolute-path-and-relative-path-file-inclusion-in-php.html" rel="nofollow">http://roshanbh.com.np/2008/01/absolute-path-and-relative-path-file-inclusion-in-php.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JT</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-861</link>
		<dc:creator>JT</dc:creator>
		<pubDate>Wed, 14 May 2008 10:27:23 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-861</guid>
		<description>DOCUMENT_ROOT is evil. Depending on server configuration, this might have a trailing slash, or it might not. So, you might write a whole site on the basis that the trailing slash doesn&#039;t exist, only to find that it does. I find it&#039;s more effective from a portability perspective to create a globally accessible configuration constant which holds the document root path to avoid this.

REQUEST_URI suffers similarly. Again, my solution is a global config constant.

I would also install a browscap.ini and use get_browser() instead of HTTP_USER_AGENT.

Alternatively to SCRIPT_FILENAME, PHP magic constants __DIR__ and __FILE__ are very useful.</description>
		<content:encoded><![CDATA[<p>DOCUMENT_ROOT is evil. Depending on server configuration, this might have a trailing slash, or it might not. So, you might write a whole site on the basis that the trailing slash doesn&#8217;t exist, only to find that it does. I find it&#8217;s more effective from a portability perspective to create a globally accessible configuration constant which holds the document root path to avoid this.</p>
<p>REQUEST_URI suffers similarly. Again, my solution is a global config constant.</p>
<p>I would also install a browscap.ini and use get_browser() instead of HTTP_USER_AGENT.</p>
<p>Alternatively to SCRIPT_FILENAME, PHP magic constants __DIR__ and __FILE__ are very useful.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tevan</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-859</link>
		<dc:creator>tevan</dc:creator>
		<pubDate>Wed, 14 May 2008 09:07:34 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-859</guid>
		<description>I&#039;m not sure about the other variables listed, but I think $_SERVER[&#039;REMOTE_ADDR&#039;] is an exception in terms of its susceptibility to dangerous manipulation.  the IP address of the remote machine can be spoofed, but it will always be in IP format, and therefore it&#039;s safe to store the REMOTE_ADDR variable as-is in your database.  that said, it wouldn&#039;t hurt to validate the REMOTE_ADDR variable first, but that may not be necessary.</description>
		<content:encoded><![CDATA[<p>I&#8217;m not sure about the other variables listed, but I think $_SERVER['REMOTE_ADDR'] is an exception in terms of its susceptibility to dangerous manipulation.  the IP address of the remote machine can be spoofed, but it will always be in IP format, and therefore it&#8217;s safe to store the REMOTE_ADDR variable as-is in your database.  that said, it wouldn&#8217;t hurt to validate the REMOTE_ADDR variable first, but that may not be necessary.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Roshan</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-854</link>
		<dc:creator>Roshan</dc:creator>
		<pubDate>Wed, 14 May 2008 04:16:28 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-854</guid>
		<description>I know some of these variables can be tampered and altered by faking http headers and you must take care of those things in your code...</description>
		<content:encoded><![CDATA[<p>I know some of these variables can be tampered and altered by faking http headers and you must take care of those things in your code&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Catalog Movies</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-853</link>
		<dc:creator>Catalog Movies</dc:creator>
		<pubDate>Wed, 14 May 2008 02:42:33 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-853</guid>
		<description>Keep in mind all of these variables should have validation. As they can be manipulated and cause havoc.</description>
		<content:encoded><![CDATA[<p>Keep in mind all of these variables should have validation. As they can be manipulated and cause havoc.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Server variables in PHP &#124; PHP Readings</title>
		<link>http://roshanbh.com.np/2008/05/useful-server-variables-php.html/comment-page-1#comment-846</link>
		<dc:creator>Server variables in PHP &#124; PHP Readings</dc:creator>
		<pubDate>Tue, 13 May 2008 11:26:18 +0000</pubDate>
		<guid isPermaLink="false">http://roshanbh.com.np/?p=107#comment-846</guid>
		<description>[...] found this great article for PHP beginners. In server variables you could find very useful information about server [...]</description>
		<content:encoded><![CDATA[<p>[...] found this great article for PHP beginners. In server variables you could find very useful information about server [...]</p>
]]></content:encoded>
	</item>
</channel>
</rss>
