Wordpress & PHP on Windows Server IIS 6
Posted By Chris in Internet Information Server, MySQL, PHP
This is a quick tip to those who are having trouble installing or using Wordpress on Windows Server with PHP.
Make sure in the PHP.ini file that the following is set:
; Magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc.
magic_quotes_runtime = Off
magic_quotes_runtime = Off
If this is ON, Wordpress will not allow you to login. It will spit out the following error:
“You do not have sufficient permissions to access this page.”
You CAN have magic_quotes ON though, which is a different setting. The above setting is for data being pulled from a MySQL database for example.
Also make sure the following is set:
; cgi.fix_pathinfo provides *real* PATH_INFO/PATH_TRANSLATED support for CGI. PHP’s
; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok
; what PATH_INFO is. For more information on PATH_INFO, see the cgi specs. Setting
; this to 1 will cause PHP CGI to fix it’s paths to conform to the spec. A setting
; of zero causes PHP to behave as before. Default is zero. You should fix your scripts
; to use SCRIPT_FILENAME rather than PATH_TRANSLATED.
cgi.fix_pathinfo=1
; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok
; what PATH_INFO is. For more information on PATH_INFO, see the cgi specs. Setting
; this to 1 will cause PHP CGI to fix it’s paths to conform to the spec. A setting
; of zero causes PHP to behave as before. Default is zero. You should fix your scripts
; to use SCRIPT_FILENAME rather than PATH_TRANSLATED.
cgi.fix_pathinfo=1
Related posts:
- Microsoft Windows Server 2003 IIS Log File Format Comparison
- Performance Tips: Disable Logging on Windows Server / IIS
- WordPress 2.1.x - 2.2 Breaks PHP 4.4.4
- Delete Spam Comments in Wordpress via MySQL
- How to install PHP ISAPI on Windows 2008 IIS7 x64
|
Print This Post
|
Hi,
I was wondering what you did in terms of directory permissions for WordPress on IIS. I can’t seem to find any resources out there.
Thanks!
You have to open up the dialog box in Windows Explorer and go to Security tab. You need to set the internet user (IUSER_ComputerName) permissions to read/view, and the config files to read/write.