Jump to content

Recommended Posts

Hi All,

 

Sorry for the very noob question but I am not a PHP programmer. I have a client that asked me to publish a website on IIS that someone else developed for them. It is all PHP and accesses a MySQL database. I got the website to display but it will not access the database. Come to find out the development was on a UNIX box. I have been able to modify the mysql_connect statement a little and it authenticated to the DB server but it will not access the data.

 

Will this work or does it need to run on a UNIX box?

 

Thanks in advance.

Link to comment
https://forums.phpfreaks.com/topic/70187-unix-vs-iis/
Share on other sites

I recognize that the problem is at the connection point with the DB. I was just using root as a test when the other users ID I had setup, which has all priviledges, would not work.

 

My concern is that this was orginally developed on a UNIX box. My only question is, "Is the PHP code different for pages developed on UNIX than if it was developed on an IIS box?" They do not want me to take the time to change the code on all of the webpages that this other company developed for them if that is what it is going to take to make it work on IIS. They would rather go back to the other company and tell them to fix it under their original contract with them.

Link to comment
https://forums.phpfreaks.com/topic/70187-unix-vs-iis/#findComment-352548
Share on other sites

It sounds like your MySQL permissions are not set up properly.

 

My only question is, "Is the PHP code different for pages developed on UNIX than if it was developed on an IIS box?"

 

Only if they used non-portable code. All of the MySQL functionality should be the same as long as the versions are.

Link to comment
https://forums.phpfreaks.com/topic/70187-unix-vs-iis/#findComment-352554
Share on other sites

The mysql version on the IIS box is 5 and the UNIX development box was 4. So looks like that may be part of the problem. Not 100% about the current PHP version as I do not have it in front of me but the original was 5.0.4

 

What is non-portable code? The reason I ask is that I was able to make a few changes to the code and get the mysql_connect statement to work.

 

Original

<? $dbclns = @mysql_connect....etc.

 

Change to:

<?php

$dbclns = @mysql_connect....etc.

 

So would the above indicate non-portable code or differences between mySQL versions.

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/70187-unix-vs-iis/#findComment-352560
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.