Code Newbie
News     Forums     Search     Members     Sign Up    

My Code Newbie
Username

Password

Articles/Snippets
ASP Classic
ASP.NET
C
C#
C++
HTML / CSS
Java
Javascript
Linux / BSD
Perl
PHP
Python
Ruby
SQL
VB 6
VB.NET

C.N. Friends
  Planet Rome

Link to Us!
Code Newbie
  Code Newbie
    forums

Go Back   Code Forums > Application and Web Development > PHP

Reply
 
LinkBack Thread Tools Display Modes
Old 08-01-2004, 03:12 AM   #1 (permalink)
eran
Registered User
 
Join Date: Aug 2004
Posts: 4
eran is on a distinguished road
cant connect to mysql databases using php

i have php5 mysql4.0.2 and apache2.0.5 installed on my windows xp. mysql on its own works fine. php works with the apache server fine too. for some reaseon my php doesnt recognize any of the mysql functions.
when i run phpinfo there is no mysql info box there but there is a "sqlite" one. i tried installing everything from scratch but it just wont work.

any ideas??
eran is offline   Reply With Quote
Old 08-01-2004, 05:56 AM   #2 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,489
sde is on a distinguished road
there are a couple mysql things you could look at in your php.ini, but the easiest thing to do is probably un-install and try again.

did you install php before mysql? when installing php/mysql on windows and using the php installer, i always install MYSQL FIRST.

what order did you install them in?
__________________
Mike
sde is offline   Reply With Quote
Old 08-01-2004, 07:21 AM   #3 (permalink)
idx
Senior Grasshopper
 
idx's Avatar
 
Join Date: Jun 2003
Location: FL
Posts: 317
idx is on a distinguished road
Quote:
when i run phpinfo there is no mysql info box there but there is a "sqlite" one.
sqlite should be there by default, but if php wasn't compiled with mysql support, you're out of luck.

Did you install these separately or use the triad project? (I recommend the triad2apache installation. )

-r
idx is offline   Reply With Quote
Old 08-01-2004, 08:18 AM   #4 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,489
sde is on a distinguished road
damn, i really need to read these posts better at 7am on sunday my advice applies to a windows/IIS installation.
__________________
Mike
sde is offline   Reply With Quote
Old 08-01-2004, 09:18 AM   #5 (permalink)
eran
Registered User
 
Join Date: Aug 2004
Posts: 4
eran is on a distinguished road
i installed mysql first. anyway php doesnt come with an installer, u just unzip into c:\php and change a few settings.
damn this thing is annoying!!
eran is offline   Reply With Quote
Old 08-01-2004, 09:25 AM   #6 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,489
sde is on a distinguished road
PHP 5.0.0 installer

http://www.php.net/downloads.php
__________________
Mike
sde is offline   Reply With Quote
Old 08-01-2004, 01:12 PM   #7 (permalink)
eran
Registered User
 
Join Date: Aug 2004
Posts: 4
eran is on a distinguished road
sde, this might sound crazy, but i used the installer and still nothing.
if you look closely in http://www.php.net/downloads.php u will see that in the 4.3.8 version it is stated that it comes with mysql support built in, but in version 5 there is no mention of that.
can you think of a way to get version 5 to support mysql if that is the case?
i think ill install version 4.3.8 as im pretty sure it will solve this problem.
eran is offline   Reply With Quote
Old 08-01-2004, 02:41 PM   #8 (permalink)
eran
Registered User
 
Join Date: Aug 2004
Posts: 4
eran is on a distinguished road
problem solved:
php 5.0.0 doesnt come with a built in support for mysql
installed php 4.3.8 and everything works fine.

thnx for the help!
eran is offline   Reply With Quote
Old 08-01-2004, 03:40 PM   #9 (permalink)
sde
Moderator
 
sde's Avatar
 
Join Date: May 2002
Location: us.ca
Posts: 4,489
sde is on a distinguished road
thanks for letting us know the solution. i thought php5 would install the same as 4.
__________________
Mike
sde is offline   Reply With Quote
Old 08-02-2004, 10:06 AM   #10 (permalink)
sammy
Code Monkey
 
sammy's Avatar
 
Join Date: Jun 2004
Location: Brooklyn/Rochester
Posts: 53
sammy is on a distinguished road
Send a message via AIM to sammy
What? PHP 5 doesnt come with support for MySQL? that seems abit strange. Does anyone know the solution to get PHP5 to work with MySQL?
__________________
sammy is offline   Reply With Quote
Old 08-02-2004, 10:03 PM   #11 (permalink)
idx
Senior Grasshopper
 
idx's Avatar
 
Join Date: Jun 2003
Location: FL
Posts: 317
idx is on a distinguished road
Compile it.

Maybe these first couple of php5 builds are going to be without mysql due to time constraints. (? just a guess)

-r
idx is offline   Reply With Quote
Old 08-07-2004, 08:02 AM   #12 (permalink)
idx
Senior Grasshopper
 
idx's Avatar
 
Join Date: Jun 2003
Location: FL
Posts: 317
idx is on a distinguished road
Check out this article on PHP5. On page 4 it mentions MySQL and the fact that its not bundled by default.

-r
idx is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
HTML form preview then INSERT using PHP & MySQL SteveSoler PHP 13 08-27-2008 10:47 PM
Simple PHP MySQL code: confused. easilyi Everything SQL ( MySQL, MSSQL, DB2, Postgre, Oracle, etc...) 4 10-24-2004 07:53 PM
MySql connect error message slappy Everything SQL ( MySQL, MSSQL, DB2, Postgre, Oracle, etc...) 2 08-23-2004 07:02 PM
csv file to mysql using php jayteema PHP 10 07-02-2004 11:20 AM
Help with setting up mySQL and PHP Ilya020 PHP 11 03-19-2003 05:10 AM


All times are GMT -8. The time now is 10:19 AM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0 RC8





Copyright © 2000-2008, Milano Interactive
Web Hosting provided by Portal 360 Web Hosting