Knowledgebase

Knowledgebase : PHP Questions
Create a blank text file called php.ini (if one doesn't already exist). Put the following line in it: memory_limit = 16M Replace 16M with the size in Megabytes you would like the limit set to. Then place the file in your public_html folder (or deeper) and that's it. YOU WILL THEN NEED TO ADD THESE LINES IN ENTIRETY TO A .HTACCESS FILE: (Please replace "yourusername" with your cpanel user name an add to the end of the command line the folder(s) to the location of the php.ini file - Also ther...
This can be done with the php.ini file. Here is how you do it: Create a file under public_html and name it php.ini (if you do not have one yet.) Put the following in it: upload_max_filesize = 5M post_max_size = 5M Replace the 5 with 20 or less. If you are letting other people upload, a size cap protects your storage space from abuse/overuse. YOU WILL THEN NEED TO ADD THESE LINES IN ENTIRETY TO A .HTACCESS FILE: (Please replace "yourusername" with your cpanel user name an add to the end...
Normally, we run PHP as CGI. On your phpinfo() page, this is the setting listed under "Server API". Shared and Reseller hosting cannot change this. Dedicated/VPS server owners can change this; just ask us to remove suPHP by opening a ticket with our Support Department along with your account details.
My PHP files all display a 500 Internal server error. How can I fix this? If you are running a PHP-based script on your site and are receiving a 500 and/or 404 errors on your pages, it is likely you have one or more of the following occurring: STEP 1: You are attempting to access PHP files through the temp-URL http://server.pacifichost.com/~username. [1]PHP on our servers requires a fully qualified domain name. You may wait until your domain has been pointed and resolves here or you may email s...
\N\NWHAT IS SUPHP IS: ON MOST APACHE SERVERS, PHP RUNS AS AN APACHE MODULE. THIS IS THE DEFAULT METHOD OF INSTALLATION. MANY HOSTS HAVE THIS SETUP BECAUSE IT IS DEFAULT AND POTENTIALLY THEY DO NOT REALIZE THAT IT IS ALSO POSSIBLE TO CONFIGURE PHP AS A CGI. RUNNING PHP AS A CGI CAN BE MORE SECURE WHILST ALSO AVOIDING FILE AND DIRECTORY OWNERSHIP ISSUES.\N\N suPHP provides the facility to have all scripts running the relevant user account instead of under the Web Servers account. This facility all...
The php.ini file is a special file for phpsuexec. The php.ini file is where you declare changes to your PHP settings. You can edit the existing php.ini, or create a new text file in any subdirectory and name it php.ini. IF YOU NEED A PHP.INI FILE FOR YOUR ACCOUNT, PLEASE CONTACT US VIA PHONE OR LIVE CHAT. WE ARE GLAD TO CREATE A REPLETE FILE FOR YOU. Some common changes that you must make when moving from non-secure php environment to phpsuexec For example, if your site had these ...
What should my php.ini file look like if my account is on a suPHP server? In php.ini, there is a different format to define your PHP settings. All lines are in the following format: SETTING_NAME = SETTING_VALUE So, this means if you move the settings from .htaccess to php.ini, you must convert the format. Let's say you have the following line in your .htaccess file: PHP_VALUE REGISTER_GLOBALS 0 the corresponding php.ini format is as follows: REGISTER_GLOBALS = OFF Notice how the value 0 becom...
PHPsuExec (pronounced sue-eksek) is a more secure environment for executable files. SuPHP is the same idea, but a more recent product specifically for PHP. All of our shared and dedicated servers have both PHPsuExec and suPHP. Only dedicated and vps has the option to remove these. This secure environment makes 777 file permissions unacceptable, and makes php.ini necessary. To verify your server is using suPHP, create a simple 'php info' script. Create a file named 'phpinfo.php' in the p...
\N\NWHAT IS SUPHP?\N\N On most Apache servers, PHP runs as an Apache module. This is the default method of installation. Many hosts have this setup because it is default and most do not realize that it is also possible to configure PHP as a CGI. Running PHP as a CGI can be more secure whilst also avoiding file and directory ownership issues. suPHP provides the facility to have all scripts run under the relevant user account instead of under the webserver's account, usually the unprivileged 'no...

Powered by WHMCompleteSolution