戰地連結︰ Home My Flickr NBA.com About

顯示包含「PHP」標籤的文章。顯示所有文章
顯示包含「PHP」標籤的文章。顯示所有文章

2009年10月9日星期五

PHP crash with some MySql functions

Overview

I has been playing with a WAMP web site using Joomla 1.5 as the CMS. Actually I am just doing the setup when I encounter this issue. When I reached the “Database Configuration” step in Joomla installation, Apache keeps crashing when I proceeded, and the Event Log said that:

Faulting application httpd.exe, version 2.2.11.0, faulting module > php5ts.dll, version 5.2.10.10, fault address 0x0000ac6a.

Again, with some Googling I found that I am not alone and there are several solutions for this issue, which is caused by wrong "libMySql.dll" module used.

Both MySQL and PHP provides the "libMySql.dll" module. When using PHP, we should use the "libMySql.dll" module provided by PHP, but not MySQL.

Reference

PHP Installation, MySQL

php使用MySql函数导致Apache(iis)崩溃的问题

PHP Crash when use some mysql function

Steps

There are several ways to solve this problem, I use the first method:

  • Rename the "libMySql.dll" file located at your MySQL “<InstallDir>/bin” folder
  • Remove your MySQL “<InstallDir>/bin” folder path from the system’s path environment variable
  • Copy the "libMySql.dll" file from your PHP install folder to “%SystemRoot%/system32” folder

2008年7月22日星期二

Installing PHP with FastCGI in Windows Server 2008 (IIS 7)

Overview

FastCGI can greatly improve the performance of CGI applications. I will share my experience of installing and configuring PHP 5.2.6 with FastCGI in Windows Server 2008 environment (the main difference is between IIS 7 and IIS 6).

Reference

Install PHP

Install IIS FastCGI

Steps

Install & Configure PHP

  1. Download PHP 5.2.6 form http://www.php.net/downloads.php
  2. Extract the ZIP file to C:\php
  3. Copy "php.ini-recommended" to the Windows directory (C:\Windows) and rename it to "php.ini"
  4. Open the "php.ini" and change the following settings"
    • extension_dir = "C:\php\extensions"
    • uncomment and set: cgi.force_redirect = 0
    • short_open_tag = On

Install & Configure IIS 7

  1. Add "Web Service" role at Windows Server 2008 "Server Manager" to install IIS 7.0
  2. Go to IIS Manager, select "Handler Mappings"
  3. Select "Add Module Mapping"
    • Input *.php in "Request Path"
    • Select "FastCgiModule" in "Module"
    • Input "C:\php\php.exe" in Executable
    • Input Name
  4. Press "OK"