Jump to content

Recommended Posts

Posted

Hi,

This is driving me insane! I have the task of installing PHP on a Windows 2003 Server with IIS. I have read quite a few tutorials and just keep getting the same result.

 

The error i keep getting is "Fatal error: Call to undefined function mysql_connect()"

 

I just cannot get PHP / MySql & IIS to work.

 

Does anyone know a tutorial that will work?

 

Regards

- Stu

Posted

Did you install PHP via the zip package? If so, there should be a file called php_mysql.dll in the /ext directory. Make sure it is there, and if it isn't, I'd download the zip package and get the file from there.

 

Next open up your php.ini file and look for this line:

 

;extension=php_mysql.dll

 

And remove the semicolon from the front:

 

extension=php_mysql.dll

Posted

Thanks again for the replies. I have done all of that. I have enable mysql extension.

 

I always restart the service after making changes.

 

Thanks

- Stuart

Posted

May have found the issue, but im just getting more confused! I set the ext direcectory to C:\php\ext in the php ini file. when i load up my phpinfo page it says the directory is C:\php5???

Any ideas

- Stuart

Posted
May have found the issue, but im just getting more confused! I set the ext direcectory to C:\php\ext in the php ini file. when i load up my phpinfo page it says the directory is C:\php5???

Any ideas

- Stuart

 

That makes me think that either the IIS service hasn't been restarted or you've made a typo in your php.ini? Where's your php.ini file stored?

  • 3 weeks later...
Posted

Arthur,

Firstly appologies with the delay in getting back to you. I have not set it up using CGI, i set it up using ISAPI.

Is CGI needed for Windows Server 2003? I set it up on an XP workstation and it worked perfectly.

Finally my PHP.ini file is in 'C:\Windows\'

 

Regards,

- Stuart

Posted (edited)
Arthur,

Firstly appologies with the delay in getting back to you. I have not set it up using CGI, I set it up using ISAPI. Is CGI needed for Windows Server 2003?

Starting with PHP v5.3, FastCGI is the recommended interface on Windows since ISAPI is no longer supported. However, if the ISAPI module is working perfectly for you then there is no reason to switch just yet. Don't even bother with CGI as it is a lot slower than FastCGI.

 

When installing PHP on Windows, I normally use the IIS Aid PHP installer since this sets everything up for you, so saves a bit of time.

 

Did you manage to get MySQL working in the end?

Edited by Arthur

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...