?
Solved

PHP-CGI Installation Problem - PHP 5.1.2

Posted on 2006-03-27
3
Medium Priority
?
347 Views
Last Modified: 2008-02-01
We have been running PHP on our internal network since version 4-2-2 (Intranet Server running Windows 2000 SP4 Server and uses IIS5.0)

PHP was initially installed to run PHPBB and then vBulletin. Under the Application Mappings section of IIS (for the Default Web Site) I configured .PHP extensions to use D:\PHP\php.exe.

Obviously, since installing PHP v4.2.2, we have upgraded the runtime a few times - we now currently run PHP 5.1.2.

Although the version of PHP has been upgraded I have not changed the Application mapping for PHP - as websites defined on our Intranet server inherit settings from the default all sites still use C:\PHP\php.exe for App Mapping (rather than PHP-cgi.exe since version 5)

All sites have worked fine until I installed a new site for SubDreamer and changed the App Mapping to PHP-cgi.exe.

I now get the error -

Fatal error: Call to undefined function mysql_connect() in D:\server-name\includes\db\mysql.php on line 34

PHP Warning: PHP Startup: Unable to load dynamic library 'D:\PHP\ext\php_mssql.dll' - The specified module could not be found. in Unknown on line 0 PHP Warning: PHP Startup: Unable to load dynamic library 'D:\PHP\ext\php_msql.dll' - The specified module could not be found. in Unknown on line 0 PHP Warning: PHP Startup: Unable to load dynamic library 'D:\PHP\ext\php_mysql.dll' - The specified module could not be found. in Unknown on line 0

PHP.ini has been amended to set extension-dir to D:\PHP\ext and the three DLL modules above can be found in the ext directory. The extension line in PHP.ini for the relevant modules has been un-commented

Changing the App Mapping back to php.exe the system works fine (except for the GD image library under SubDreamer which is how I found this problem in the first place)

Any clues?  
0
Comment
Question by:PKFIOM
3 Comments
 
LVL 48

Expert Comment

by:hernst42
ID: 16298680
AFAIK the mysql-extension under php 5 needs a mysqlclient.dll of version 4.x. So check which mysqlclient.dll you have installed on your system and replace (after the backup of the old one) it with an uptodate version.
0
 
LVL 2

Expert Comment

by:WaielEid
ID: 16298782
'D:\PHP\ext\php_mssql.dll'  is for MS SQL not MYSQL
as for php_mysql.dll

you can get it from here : http://pecl.php.net/package/mysql and add it to your ext direcrory
Some of these DLLs are not bundled with the PHP distribution. so you can find the dll in this site http://pecl.php.net 
0
 
LVL 11

Accepted Solution

by:
siliconbrit earned 2000 total points
ID: 16298910

On the release of version 5, PHP is no longer configured to support MySQL *by default*.  The support is still available, but you need to turn it on.  Details on this can be found on the PHP site at:

   http://uk.php.net/mysql

..with instructions on how to configure manually for Windows at:

   http://uk.php.net/manual/en/install.windows.manual.php

Please note that this was a well-publicised change in the PHP5 release.  Whenever you move to a new version of some infrastructure component, you should check the release notes.  These are in a file included with your PHP installation, and also published online at:

   http://uk.php.net/README_UPGRADE_51.php

..plus there is a complete guide to migration from 4.x.x to 5.x.x at:  

   http://uk.php.net/manual/en/faq.migration5.php

Good Luck
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses
Course of the Month16 days, 23 hours left to enroll

862 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question