How do I create a custom php.ini file?

A custom php.ini file can be constructed and placed in your web account. For instance, using a text editor such as Notepad, you can create a php.ini file with the following custom setting which would override our default server setting:

 

file_uploads=off


The php.ini file should only contain the custom settings - each on its own line (such as the above example). When completed, save the file and upload it to an area (folder) on your web account where the rest of your php files are located. 

NOTE: The php.ini file should be uploaded into every folder and/or subfolder where the settings need to take place.  Be sure to rename your php.txt file to php.ini before you upload it to your server.

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Creating a simple, safe contact form

If you've ever wanted a feedback or contact form on your website, you may find the following code...

Cron jobs

A 'cron job' is an automated task that can be set up within your cPanel. This will typically be...

File permissions

There are a number of file permissions, which can be used for a variety of different purposes,...

How to change the date.timezone value in PHP?

If your PHP scripts do not show the correct time, the reason is that most probably your hosting...