<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Linux Servers cPanel webhosting blog &#187; Enable private PHP</title>
	<atom:link href="http://www.theperfectarts.com/category/enable-private-php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.theperfectarts.com</link>
	<description>Basics cPanel tutorials / issue,mysql,php errors etc</description>
	<lastBuildDate>Wed, 08 Feb 2012 05:58:30 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Test php script to check the exec php function</title>
		<link>http://www.theperfectarts.com/2011/11/test-php-script-to-check-the-exec-php-function/</link>
		<comments>http://www.theperfectarts.com/2011/11/test-php-script-to-check-the-exec-php-function/#comments</comments>
		<pubDate>Sun, 20 Nov 2011 11:55:27 +0000</pubDate>
		<dc:creator>Gunjan</dc:creator>
				<category><![CDATA[Enable private PHP]]></category>
		<category><![CDATA[Linux Administrator Interview Questions]]></category>
		<category><![CDATA[VPS]]></category>
		<category><![CDATA[cehck php exec function]]></category>
		<category><![CDATA[how to check php exec disable]]></category>
		<category><![CDATA[how to check php exec function enable]]></category>
		<category><![CDATA[php exec function]]></category>
		<category><![CDATA[php exec function issue]]></category>
		<category><![CDATA[problem to chek exec function]]></category>
		<category><![CDATA[script to check exec function]]></category>
		<category><![CDATA[simple test script for exec function]]></category>
		<category><![CDATA[test exec function]]></category>

		<guid isPermaLink="false">http://www.theperfectarts.com/?p=1628</guid>
		<description><![CDATA[Simple php script to check if exec php function is enabled or not because many shared hosting provider by default disabled the exec php function to secure the server. You can refer the following script to check exec php function. Login in to the cPanel and create the new file test.php and insert the following [...]]]></description>
			<content:encoded><![CDATA[<p>Simple php script to check if exec php function is enabled or not because many shared hosting provider by default disabled the exec php function to secure the server. You can refer the following script to check exec php function.</p>
<p>Login in to the cPanel and create the new file test.php and insert the following code.</p>
<blockquote><p><strong>&lt;?php</strong><br />
<strong>echo exec(&#8216;whoami&#8217;);</strong><br />
<strong>?&gt;</strong></p></blockquote>
<p><script type="text/javascript"><!--
google_ad_client = "ca-pub-1685490665026631";
/* Big images */
google_ad_slot = "0185136902";
google_ad_width = 336;
google_ad_height = 280;
//-->
</script><br />
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
<p><script type="text/javascript">// <![CDATA[
     var _gaq = _gaq || [];   _gaq.push(['_setAccount', 'UA-27772211-1']);   _gaq.push(['_trackPageview']);   (function() {     var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;     ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';     var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);   })();
// ]]&gt;</script><br />
Now browse the URL <strong>yourdomain.com/test.php</strong> , it will show your cPanel user name if exec php function is enabled on the server and if exec php function is disabled on your domain hosted server then you will receive the following error after browsing the URL yourdomain.com/test.php</p>
<p><strong>Warning: exec() has been disabled for security reasons in /home/cpanel_username/public_html/test.php on line 2</strong></p>
<p>You can contact your hosting provider and ask them to enable the exec function. If you have any query let me know at nsk.gunjan@gmail.com</p>
<p>&copy;2012 <a href="http://www.theperfectarts.com">Linux Servers cPanel webhosting blog</a>. All Rights Reserved.</p>.]]></content:encoded>
			<wfw:commentRss>http://www.theperfectarts.com/2011/11/test-php-script-to-check-the-exec-php-function/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Disable php for single hosting account.</title>
		<link>http://www.theperfectarts.com/2010/05/disable-php-for-single-hosting-account/</link>
		<comments>http://www.theperfectarts.com/2010/05/disable-php-for-single-hosting-account/#comments</comments>
		<pubDate>Wed, 05 May 2010 12:46:31 +0000</pubDate>
		<dc:creator>Gunjan</dc:creator>
				<category><![CDATA[Enable private PHP]]></category>
		<category><![CDATA[Linux Administrator Interview Questions]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Disable php]]></category>
		<category><![CDATA[php_value]]></category>

		<guid isPermaLink="false">http://www.theperfectarts.com/?p=1010</guid>
		<description><![CDATA[We can disable the php for single hosting account by using following code in .htaccess file. php_value engine off &#169;2012 Linux Servers cPanel webhosting blog. All Rights Reserved..]]></description>
			<content:encoded><![CDATA[<p>We can disable the php for single hosting account by using following code in .htaccess file.</p>
<p><strong><code>php_value engine off</code></strong></p>
<input type="hidden" name="IL_RELATED_TAGS" value="1" />
<script type="text/javascript">// <![CDATA[
 google_ad_client = "ca-pub-1685490665026631"; /* images */ google_ad_slot = "1433358698"; google_ad_width = 300; google_ad_height = 250;
// ]]&gt;</script></p>
<p><script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js">// <![CDATA[</p>
<p>// ]]&gt;</script></p>
<p>&copy;2012 <a href="http://www.theperfectarts.com">Linux Servers cPanel webhosting blog</a>. All Rights Reserved.</p>.]]></content:encoded>
			<wfw:commentRss>http://www.theperfectarts.com/2010/05/disable-php-for-single-hosting-account/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Send mail by using phpmail function.</title>
		<link>http://www.theperfectarts.com/2009/09/send-mail-by-using-phpmail-function/</link>
		<comments>http://www.theperfectarts.com/2009/09/send-mail-by-using-phpmail-function/#comments</comments>
		<pubDate>Mon, 21 Sep 2009 04:28:58 +0000</pubDate>
		<dc:creator>Gunjan</dc:creator>
				<category><![CDATA[E-mails issue]]></category>
		<category><![CDATA[Enable private PHP]]></category>
		<category><![CDATA[Few good queries and suggestions]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[check phpmail() function]]></category>
		<category><![CDATA[enable or disable the phpmail() function]]></category>
		<category><![CDATA[not sure phpmail]]></category>
		<category><![CDATA[php form]]></category>
		<category><![CDATA[phpmail function]]></category>
		<category><![CDATA[PHPMAIL function solution]]></category>
		<category><![CDATA[phpmail() form]]></category>
		<category><![CDATA[phpmail() function issue]]></category>
		<category><![CDATA[phpmail() function problem]]></category>
		<category><![CDATA[phpmail() test script]]></category>
		<category><![CDATA[resolve phpmail() function issue]]></category>
		<category><![CDATA[simple php form]]></category>
		<category><![CDATA[simple phpmail function form]]></category>
		<category><![CDATA[simple phpmail() form]]></category>
		<category><![CDATA[test contact for phpmail() function]]></category>
		<category><![CDATA[what is phpmail]]></category>

		<guid isPermaLink="false">http://www.theperfectarts.com/?p=246</guid>
		<description><![CDATA[You can create a simple php mail form by using following code.. &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; &#60;? $to      = &#8216;supp0rt@xyz.com&#8217;; $subject = &#8216;The test for mail function&#8217;; $message = &#8216;Hello&#8217;; $headers = &#8216;From: test@abc123.com&#8217; . &#8220;\r\n&#8221; . &#8216;Reply-To: test@testforever123.com&#8217; . &#8220;\r\n&#8221; . &#8216;X-Mailer: PHP/&#8217; . phpversion(); mail($to, $subject, $message, $headers); ?&#62; &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; If you are not able to [...]]]></description>
			<content:encoded><![CDATA[<p>You can create a simple php mail form by using following code..</p>
<blockquote><p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;</p>
<p><strong><span style="color: #800000;">&lt;?<br />
$to      = &#8216;supp0rt@xyz.com&#8217;;<br />
$subject = &#8216;The test for mail function&#8217;;<br />
$message = &#8216;Hello&#8217;;<br />
$headers = &#8216;From: test@abc123.com&#8217; . &#8220;\r\n&#8221; .<br />
&#8216;Reply-To: test@testforever123.com&#8217; . &#8220;\r\n&#8221; .<br />
&#8216;X-Mailer: PHP/&#8217; . phpversion();<br />
mail($to, $subject, $message, $headers);<br />
?&gt;</span></strong></p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;</p></blockquote>
<p>If you are not able to receive the E-mail then you need to check whether your server is allowing to send an E-mail by using phpmail() or not?&#8217; if you are having root login then check the servers main php.ini file.</p>
<p><script type="text/javascript">// <![CDATA[
 google_ad_client = "ca-pub-1685490665026631"; /* images */ google_ad_slot = "1433358698"; google_ad_width = 300; google_ad_height = 250;
// ]]&gt;</script></p>
<p><script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js">// <![CDATA[</p>
<p>// ]]&gt;</script></p>
<blockquote><p><strong><span style="color: #800000;">root@Gunjan []# php -i | grep php.ini<br />
Configuration File (php.ini) Path =&gt; /usr/local/lib<br />
Loaded Configuration File =&gt; /usr/local/lib/php.ini</span></strong></p>
<p><strong><span style="color: #800000;">root@Gunjan []# cat /usr/local/lib/php.ini | grep disable_function<br />
disable_functions=&#8221;system,passthru,popen,proc_close,proc_get_status,proc_nice,proc_open,proc_terminate,shell_exec,highlight_file,phpmail&#8221;</span></strong></p></blockquote>
<p>and remove the phpmail() from server mail php.ini file and restart the Apache web server.</p>
<p>Or</p>
<p>If you are not having root login details then contact your hosting provider and ask them to enable the phpmail() for your hosting account.</p>
<p>You can also send me an E-mail at nsk.gunjan@gmail.com if you have any queries&#8230;</p>
<p>&copy;2012 <a href="http://www.theperfectarts.com">Linux Servers cPanel webhosting blog</a>. All Rights Reserved.</p>.]]></content:encoded>
			<wfw:commentRss>http://www.theperfectarts.com/2009/09/send-mail-by-using-phpmail-function/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to disbale Directory listing for folders?</title>
		<link>http://www.theperfectarts.com/2009/09/how-to-disbale-directory-listing-for-folders/</link>
		<comments>http://www.theperfectarts.com/2009/09/how-to-disbale-directory-listing-for-folders/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 22:47:48 +0000</pubDate>
		<dc:creator>Gunjan</dc:creator>
				<category><![CDATA[Basic Linux]]></category>
		<category><![CDATA[Browser problems]]></category>
		<category><![CDATA[Enable private PHP]]></category>
		<category><![CDATA[Linux Permissions]]></category>
		<category><![CDATA[Directory listing for folders]]></category>
		<category><![CDATA[disbale Directory listing for folders]]></category>

		<guid isPermaLink="false">http://www.theperfectarts.com/?p=208</guid>
		<description><![CDATA[To disable the Directory listing for folders you need to create the .htaccess file under the each an every folder under which you want to disable the Directory listing and insert the following code in .htaccess file. &#8212;&#8212;&#8212;&#8212; Options -Indexes &#8212;&#8212;&#8212;&#8212; Please contact us if you have any problem or queries&#8230;.. &#169;2012 Linux Servers cPanel [...]]]></description>
			<content:encoded><![CDATA[<p>To disable the Directory listing for folders you need to create the .htaccess file under the each an every folder under which you want to disable the Directory listing and insert the following code in .htaccess file.</p>
<p>&#8212;&#8212;&#8212;&#8212;<br />
Options -Indexes<br />
&#8212;&#8212;&#8212;&#8212;</p>
<p>Please contact us if you have any problem or queries&#8230;..<br />
<script type="text/javascript">// <![CDATA[
 google_ad_client = "ca-pub-1685490665026631"; /* images */ google_ad_slot = "1433358698"; google_ad_width = 300; google_ad_height = 250;
// ]]&gt;</script></p>
<p><script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js">// <![CDATA[</p>
<p>// ]]&gt;</script></p>
<p>&copy;2012 <a href="http://www.theperfectarts.com">Linux Servers cPanel webhosting blog</a>. All Rights Reserved.</p>.]]></content:encoded>
			<wfw:commentRss>http://www.theperfectarts.com/2009/09/how-to-disbale-directory-listing-for-folders/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Enable private PHP Error Logging by using .htaccess file</title>
		<link>http://www.theperfectarts.com/2009/08/enable-private-php-error-logging-by-using-htaccess-file/</link>
		<comments>http://www.theperfectarts.com/2009/08/enable-private-php-error-logging-by-using-htaccess-file/#comments</comments>
		<pubDate>Thu, 20 Aug 2009 22:17:36 +0000</pubDate>
		<dc:creator>Gunjan</dc:creator>
				<category><![CDATA[Enable private PHP]]></category>
		<category><![CDATA[Error Logging by using .htaccess]]></category>
		<category><![CDATA[PHP Error]]></category>

		<guid isPermaLink="false">http://www.theperfectarts.com/2008/09/enable-private-php-error-logging-by-using-htaccess-file/</guid>
		<description><![CDATA[To hide the PHP errors from visitors insert the following code in .htaccess file # Disable php errors php_flag display_startup_errors off php_flag display_errors off php_flag html_errors off Once disable the error logs for visitors enable the private PHP error logging by using following code in the .htaccess file # enable PHP error logging php_flag log_errors [...]]]></description>
			<content:encoded><![CDATA[<p>To hide the PHP errors from visitors insert the following code in .htaccess file</p>
<p># Disable php errors<br />
php_flag display_startup_errors off<br />
php_flag display_errors off<br />
php_flag html_errors off</p>
<p>Once disable the error logs for visitors enable the private PHP error logging by using following code in the .htaccess file</p>
<p># enable PHP error logging<br />
php_flag log_errors on<br />
php_value error_log /home/path/public_html/domain/PHP_errors.log</p>
<p>The PHP_errors.log file needs to be permission 755 or 777.</p>
<div class="blogger-post-footer">http://www.host.co.in/forums/f37/how-check-if-server-suexec-not-821/</div>
<p>&copy;2012 <a href="http://www.theperfectarts.com">Linux Servers cPanel webhosting blog</a>. All Rights Reserved.</p>.]]></content:encoded>
			<wfw:commentRss>http://www.theperfectarts.com/2009/08/enable-private-php-error-logging-by-using-htaccess-file/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

