Home » Categories » Web Hosting

How can I change the php.ini settings in my Windows hosting account?

Your configuration will default to the global php.ini on the server unless you put a php.ini file in the root directory, below the public_html directory.

To avoid problems, you must set:

cgi.force_redirect=0

This is necessary for PHP to work inside IIS.

For Zend Optimizer and ionCube loader to work as well, you will need to add the following lines:

zend_extension_ts="C:\ioncube\ioncube\ioncube_loader_win_5.2.dll"
zend_extension_manager.optimizer_ts="C:\Program Files\Zend\ZendOptimizer-3.3.0\lib\Optimizer-3.3.0"
zend_extension_ts="C:\Program Files\Zend\ZendOptimizer-3.3.0\lib\ZendExtensionManager.dll"

And for other extensions, you will need to declare the extension directory, followed by the relevant extension directive.

For example:

extension_dir="C:\PHP\ext"
extension=php_mysql.dll
extension=php_mbstring.dll

Unfortunately, even after you change the php.ini settings, they will not work for the temporary URL. You will need to be on the live domain in order to see them work.

3 (4)
Article Rating (4 Votes)
Rate this article
  • Icon PDFExport to PDF
Related Articles
How do I redirect my site?
Added on Tue, Mar 17, 2015