Help me in installing PHP5 with MySQL 5

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
sj1983msh
Forum Newbie
Posts: 15
Joined: Thu Feb 28, 2008 12:01 pm

Help me in installing PHP5 with MySQL 5

Post by sj1983msh »

Hi guys,

I have faced a problem with my new MySQL and PHP.
I have been using PHP5 and MySQL 4 for 3 years. But recently I decided to update my MySQL Version to 5 series.
I have removed MySQL 4 and then Installed the new version, but my PHP scripts doesn't work (can not connect to MySQL Server) for connecting to MySQL.
I tested MySQL from Command-Prompt and it works properly. But when I tried to connect via a Script, the code doesn't work and the IE shows me this warning:

Warning: mysql_connect() [function.mysql-connect]: Client does not support authentication protocol requested by server; consider upgrading MySQL client in c:\Inetpub\wwwroot\PHPTest\testlocalserver.php on line 12

Please tell me what should I do to install the MySQL 5 correctly.
Which kind of .DLLs or files I should have for PHP to Configure it!?
Please tell me anything you think it is necessary, because I am not a professional.
I do not know what to do! :(
Please help me.

I use these > Windows XP (SP2), IIS, PHP5

Thanks a lot.

Sincerely Yours
Saman J.
cooljaguar
Forum Newbie
Posts: 3
Joined: Wed Apr 30, 2008 11:35 am

Re: Help me in installing PHP5 with MySQL 5

Post by cooljaguar »

Hello

I also have the same problem.

Could anyone help me please :roll:
sj1983msh
Forum Newbie
Posts: 15
Joined: Thu Feb 28, 2008 12:01 pm

Re: Help me in installing PHP5 with MySQL 5

Post by sj1983msh »

What is your main problem with this process exactly? :(
cooljaguar
Forum Newbie
Posts: 3
Joined: Wed Apr 30, 2008 11:35 am

Re: Help me in installing PHP5 with MySQL 5

Post by cooljaguar »

Actually I installed PHP5.2.5 and MySQL 5.0.51b in Windows.

I am not able to find a way to configure PHP with MySQL,

I copied the libmysql.dll to the php folder and added that to the php.ini.

When i see the phpinfo, I am not able to find mysql in that and write a sample code like this I am not getting any error or the result

echo "Hai ";
$database="test";
$user="root";
$password="asas";
echo "<br> Before Connecting to the database ";
$conn=mysql_connect("localhost",$user,$password);
if(!$conn){
echo "<br> Could not establish the connection";
}
else{
echo "<br> connection established";
echo "Connecting to the database ";
mysql_select_db($database,$conn);
echo "Selecting the database ";
$query="select * from test";

$result=mysql_query($query);
while($row=mysql_fetch_array($result)){
echo " in printing the rows";
echo $row[0];
echo $row[1];
echo"<br>";
}

}
cooljaguar
Forum Newbie
Posts: 3
Joined: Wed Apr 30, 2008 11:35 am

Re: Help me in installing PHP5 with MySQL 5

Post by cooljaguar »

By the way,I am using apache 2.0
User avatar
VladSun
DevNet Master
Posts: 4313
Joined: Wed Jun 27, 2007 9:44 am
Location: Sofia, Bulgaria

Re: Help me in installing PHP5 with MySQL 5

Post by VladSun »

If it's not a WAMP related problem, then google for old_password MySQL - that is for granting access to MySQL databases.
There are 10 types of people in this world, those who understand binary and those who don't
Post Reply