Sunday, 9 June 2013

What are important settings in php.ini

Well - If you open the php.ini file, you will get to see lot of php settings. This file is located in your php installation folder.

Below is the list of important settings in php.ini that you will need to edit.

  1. max_execution_time : This setting is used to set the maximum execution time of your php script. By default it is 30 seconds. But if your script needs to fetch data from other server, it may take longer. In that case you need to increase this setting.
  2. error_reportingThis setting is used to set the level of error reporting. It controls what kinds of errors are displayed to user. default is E_ALL means php shows all kinds of errors to user.
  3. display_errorsThis setting is used to show or hide errors to user. If it is set to off, no errors are displayed to user.
  4. include_pathThis setting is used to set the path of directory from where you can include or require files.
  5. file_uploadsThis setting is used for uploading the file, if on, you can upload files to server using php.
  6. mysql.default_hostThis setting is used to specify default mysql server.
  7. post_max_sizeThis setting is used to specify the maximum size in mb that can be posted using post method.
  8. uploa_tmp_dirThis setting is used to specify the temporary directory for uploads.
There are many more settings in php.ini But above mentioned are very important settings in php.

No comments:

Post a Comment