#45338 [Com]: PHP 5.2.6 does not connect to MySQL

2008-07-31 Thread tpeterson at americaschoice dot org
 ID:   45338
 Comment by:   tpeterson at americaschoice dot org
 Reported By:  tpeterson at americaschoice dot org
 Status:   Assigned
 Bug Type: Dynamic loading
 Operating System: Windows NT
 PHP Version:  5.2.6
 Assigned To:  jmetric
 New Comment:

OK. I found a blank WIndows XP box. Installed Apache and then PHP (your
installer). This time I could not get PHP to work. I tried everything.
Even the Apache syntax was ok. So I got the PHP.ini file from another
machine where the WAMP worked and overwrote the new install's php.ini
file. Restarted PHP and PHP worked. I have not had time to set up MySQL.
But there is definitely something wrong with the installer for the
latest PHP build. Also, I noted that all the exentions were once again
uncommented in the php.ini file. No one should/would have all those
extensions turned on, at least for security reasons. Also, the problem
with the MySQL was because you said you no longer supported it and it
had to be uncommented out. So why does the installer install it
pre-uncommented? There is something whack about that build.


Previous Comments:


[2008-07-14 13:26:57] tpeterson at americaschoice dot org

Thanks, SWilliams, for the comment. I did do that. I checked the path
and rechecked it . . . actually I double and triple checked everything.
My students also did so many installs/uninstalls/checks that on the
evaluation they suggested it be installed for the next class before the
class begins (which I will do and just distribute a hand out on how to
set up their own environments at home or work).  I will in the next few
weeks install this on a brand new machine that has never had anything
installed on it, including but not limited to PHP, MySQL, and Apache,
and see what results I get.



[2008-07-12 17:10:20] swilliams at csc dot edu

Make sure that you have set your path environment variable to include
your php and php extensions directory.  I ran into the same problem, and
after I adjusted my path variable, I restarted my computer and
everything worked fine.  Hope this helps.



[2008-07-03 19:53:08] tpeterson at americaschoice dot org

I searched for all old mysql .dll files as the documentation said and
for all .ini files. I deleted any old ones. I restarted--the computer
and the server. I did this so many times. I was as thorough with
this as possible. Also, during the class that I taught, this was the
first install as this was the first PHP class. It wasn't just me and my
laptop. I also used a work laptop. It was all the students in that
class. Even students who did this at home with your installer, after the
class was over, couldn't get it to work. So this is not an old ini
issue. The ini that was used was the one that your installer set up. And
as I said the ini that your installer installed on the systems had
everything uncommented. If MySQL, for instance, is not supported why was
everything, including the MySQL extension uncommented upon a base
install? First install? Anyway, I already thought of this and verified
the ini used was the one that I was edited. 

I will find yet another clean laptop and install the WAMP stack on it
with this installer and see if there is still an issue.



[2008-07-02 11:43:52] [EMAIL PROTECTED]

It just means that PHP is actually using different (old?) php.ini file
than the one you're editing. Check from phpinfo() output what the actual
_loaded_ php.ini file is.



[2008-06-29 15:01:48] tpeterson at americaschoice dot org

Yes, I know. The file is there, as I said in my write-up. It still
won't work.



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/45338

-- 
Edit this bug report at http://bugs.php.net/?id=45338&edit=1



#45338 [Com]: PHP 5.2.6 does not connect to MySQL

2008-07-14 Thread tpeterson at americaschoice dot org
 ID:   45338
 Comment by:   tpeterson at americaschoice dot org
 Reported By:  tpeterson at americaschoice dot org
 Status:   Assigned
 Bug Type: Dynamic loading
 Operating System: Windows NT
 PHP Version:  5.2.6
 Assigned To:  jmetric
 New Comment:

Thanks, SWilliams, for the comment. I did do that. I checked the path
and rechecked it . . . actually I double and triple checked everything.
My students also did so many installs/uninstalls/checks that on the
evaluation they suggested it be installed for the next class before the
class begins (which I will do and just distribute a hand out on how to
set up their own environments at home or work).  I will in the next few
weeks install this on a brand new machine that has never had anything
installed on it, including but not limited to PHP, MySQL, and Apache,
and see what results I get.


Previous Comments:


[2008-07-12 17:10:20] swilliams at csc dot edu

Make sure that you have set your path environment variable to include
your php and php extensions directory.  I ran into the same problem, and
after I adjusted my path variable, I restarted my computer and
everything worked fine.  Hope this helps.



[2008-07-03 19:53:08] tpeterson at americaschoice dot org

I searched for all old mysql .dll files as the documentation said and
for all .ini files. I deleted any old ones. I restarted--the computer
and the server. I did this so many times. I was as thorough with
this as possible. Also, during the class that I taught, this was the
first install as this was the first PHP class. It wasn't just me and my
laptop. I also used a work laptop. It was all the students in that
class. Even students who did this at home with your installer, after the
class was over, couldn't get it to work. So this is not an old ini
issue. The ini that was used was the one that your installer set up. And
as I said the ini that your installer installed on the systems had
everything uncommented. If MySQL, for instance, is not supported why was
everything, including the MySQL extension uncommented upon a base
install? First install? Anyway, I already thought of this and verified
the ini used was the one that I was edited. 

I will find yet another clean laptop and install the WAMP stack on it
with this installer and see if there is still an issue.



[2008-07-02 11:43:52] [EMAIL PROTECTED]

It just means that PHP is actually using different (old?) php.ini file
than the one you're editing. Check from phpinfo() output what the actual
_loaded_ php.ini file is.



[2008-06-29 15:01:48] tpeterson at americaschoice dot org

Yes, I know. The file is there, as I said in my write-up. It still
won't work.



[2008-06-29 11:13:57] simonclur at gmail dot com

PHP v5.2.6 requires to the php_mysql.dll (v5.2.6) dll to connect to
MySql. 

It appears the PHP v5.2.6 .msi installation package apparently does not
copy the new php_mysql.dll into the ./ext directory as it is supposed
to.

Download the .zip version of php v5.2.6 and copy the php_mysql.dll file
from the zip archive to your /php/ext folder and make sure the following
line in your php.ini file is uncommented.

extension=php_mysql.dll

If you're having problems with "Unable to initialize module" for
php_mysql.dll then you have copied an incorrect version from a previous
or later release of php.

The php_mysql.dll file properties should show the following version
information for the dll:
File version: 5.2.6
Created: 11 January 2006 18h15



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/45338

-- 
Edit this bug report at http://bugs.php.net/?id=45338&edit=1



#45338 [Com]: PHP 5.2.6 does not connect to MySQL

2008-07-03 Thread tpeterson at americaschoice dot org
 ID:   45338
 Comment by:   tpeterson at americaschoice dot org
 Reported By:  tpeterson at americaschoice dot org
 Status:   Assigned
 Bug Type: Dynamic loading
 Operating System: Windows NT
 PHP Version:  5.2.6
 Assigned To:  jmetric
 New Comment:

I searched for all old mysql .dll files as the documentation said and
for all .ini files. I deleted any old ones. I restarted--the computer
and the server. I did this so many times. I was as thorough with
this as possible. Also, during the class that I taught, this was the
first install as this was the first PHP class. It wasn't just me and my
laptop. I also used a work laptop. It was all the students in that
class. Even students who did this at home with your installer, after the
class was over, couldn't get it to work. So this is not an old ini
issue. The ini that was used was the one that your installer set up. And
as I said the ini that your installer installed on the systems had
everything uncommented. If MySQL, for instance, is not supported why was
everything, including the MySQL extension uncommented upon a base
install? First install? Anyway, I already thought of this and verified
the ini used was the one that I was edited. 

I will find yet another clean laptop and install the WAMP stack on it
with this installer and see if there is still an issue.


Previous Comments:


[2008-07-02 11:43:52] [EMAIL PROTECTED]

It just means that PHP is actually using different (old?) php.ini file
than the one you're editing. Check from phpinfo() output what the actual
_loaded_ php.ini file is.



[2008-06-29 15:01:48] tpeterson at americaschoice dot org

Yes, I know. The file is there, as I said in my write-up. It still
won't work.



[2008-06-29 11:13:57] simonclur at gmail dot com

PHP v5.2.6 requires to the php_mysql.dll (v5.2.6) dll to connect to
MySql. 

It appears the PHP v5.2.6 .msi installation package apparently does not
copy the new php_mysql.dll into the ./ext directory as it is supposed
to.

Download the .zip version of php v5.2.6 and copy the php_mysql.dll file
from the zip archive to your /php/ext folder and make sure the following
line in your php.ini file is uncommented.

extension=php_mysql.dll

If you're having problems with "Unable to initialize module" for
php_mysql.dll then you have copied an incorrect version from a previous
or later release of php.

The php_mysql.dll file properties should show the following version
information for the dll:
File version: 5.2.6
Created: 11 January 2006 18h15

----

[2008-06-23 17:54:13] tpeterson at americaschoice dot org

Description:

I have installed Apache 2.2.9, PHP 5.2.6, and MySQL 5.0 on Windows. PHP
and Apache work. PHP and MySQL do not. But, MySQL does work on its own.


I used the PHP installer for php.net downloads page. 

I keep getting the Fatal error: Call to undefined function
mysql_connect() in C:\Program Files\Apache Software
Foundation\Apache2.2\htdocs\processex.php on line 15 error when I try to
connect to my MySQL database from a PHP script.

I did the following:
1) Installed Apache, PHP, and MySQL
2) Ensured that I can run a PHP with built-in functions and display it
in my browser with Apache serving it up.
3) Log into MySQL and create a database.
4) Located the extensions path my php.ini file and ensured that my
.dlls were in it
5) Located the mysql extension statements in the php.ini file and
uncommented them (removed the semicolon before each of them EVEN THOUGH
THE MYSQL ONES WERE ALREADY UNCOMMENTED IN THIS DOWNLOAD ALTHOUGH YOU
SAY THERE IS NOT BUILT IN SUPPORT).
6) Ensured that both PHP and MySQL have entries in the System Path. 
7) Restarted the server
8) Restarted my computer. 

I got the same error. I looked at the phpinfo() and used
get_loaded_extensions() function output but saw that mysql is not
installed.

Then I did what the documentation in several places on the internet
said to do:
I deleted all the libmysql.dll and php_mysql.dll files except the ones
in the php directory and then copied them to the windows/system32
directory and restarted my computer. I still get the same error message.
Still do not see mysql installed with the phpinfo() or
get_loaded_extensions(). 

I then did the following, which is what another user suggested:
Download the PHP zip distribution and copy the .dlls out of that into
my php directory that the installer installed. No luck. I still get the
same error message.Still do not see mysql installed with the phpinfo()
or get_loaded_extensions(). 

I also tried to load php_mysql.dll with the dl() function but no luck
as I am using a multi-threaded server. 

Someone on th

#45338 [Com]: PHP 5.2.6 does not connect to MySQL

2008-06-29 Thread tpeterson at americaschoice dot org
 ID:   45338
 Comment by:   tpeterson at americaschoice dot org
 Reported By:  tpeterson at americaschoice dot org
 Status:   Assigned
 Bug Type: *Configuration Issues
 Operating System: Windows NT
 PHP Version:  5.2.6
 Assigned To:  jmetric
 New Comment:

Yes, I know. The file is there, as I said in my write-up. It still
won't work.


Previous Comments:


[2008-06-29 11:13:57] simonclur at gmail dot com

PHP v5.2.6 requires to the php_mysql.dll (v5.2.6) dll to connect to
MySql. 

It appears the PHP v5.2.6 .msi installation package apparently does not
copy the new php_mysql.dll into the ./ext directory as it is supposed
to.

Download the .zip version of php v5.2.6 and copy the php_mysql.dll file
from the zip archive to your /php/ext folder and make sure the following
line in your php.ini file is uncommented.

extension=php_mysql.dll

If you're having problems with "Unable to initialize module" for
php_mysql.dll then you have copied an incorrect version from a previous
or later release of php.

The php_mysql.dll file properties should show the following version
information for the dll:
File version: 5.2.6
Created: 11 January 2006 18h15



[2008-06-23 17:54:13] tpeterson at americaschoice dot org

Description:

I have installed Apache 2.2.9, PHP 5.2.6, and MySQL 5.0 on Windows. PHP
and Apache work. PHP and MySQL do not. But, MySQL does work on its own.


I used the PHP installer for php.net downloads page. 

I keep getting the Fatal error: Call to undefined function
mysql_connect() in C:\Program Files\Apache Software
Foundation\Apache2.2\htdocs\processex.php on line 15 error when I try to
connect to my MySQL database from a PHP script.

I did the following:
1) Installed Apache, PHP, and MySQL
2) Ensured that I can run a PHP with built-in functions and display it
in my browser with Apache serving it up.
3) Log into MySQL and create a database.
4) Located the extensions path my php.ini file and ensured that my
.dlls were in it
5) Located the mysql extension statements in the php.ini file and
uncommented them (removed the semicolon before each of them EVEN THOUGH
THE MYSQL ONES WERE ALREADY UNCOMMENTED IN THIS DOWNLOAD ALTHOUGH YOU
SAY THERE IS NOT BUILT IN SUPPORT).
6) Ensured that both PHP and MySQL have entries in the System Path. 
7) Restarted the server
8) Restarted my computer. 

I got the same error. I looked at the phpinfo() and used
get_loaded_extensions() function output but saw that mysql is not
installed.

Then I did what the documentation in several places on the internet
said to do:
I deleted all the libmysql.dll and php_mysql.dll files except the ones
in the php directory and then copied them to the windows/system32
directory and restarted my computer. I still get the same error message.
Still do not see mysql installed with the phpinfo() or
get_loaded_extensions(). 

I then did the following, which is what another user suggested:
Download the PHP zip distribution and copy the .dlls out of that into
my php directory that the installer installed. No luck. I still get the
same error message.Still do not see mysql installed with the phpinfo()
or get_loaded_extensions(). 

I also tried to load php_mysql.dll with the dl() function but no luck
as I am using a multi-threaded server. 

Someone on the internet said to try deleting the php_mysql.dll and
libmysql.dll and using the ones from MySQL. I just checked and mysql is
only offering mysqli and a replacement for libmysql which I do not want
to get into just yet. 

I can get this installed (WAMP) and working if I use, for example,
xampp. So this tells me there is something wrong with your PHP
code/documentation. 

I am not the only one who has tried. I was teaching a class and all the
students tried individually at school and at home with no luck. I tried
this on my Windows XP and Windows NT laptops. Nothing. 


Reproduce code:
---
// we connect to example.com and port 3307
$link = mysql_connect('localhost', 'root', 'password');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);

Expected result:

That I get "Connected successfully" and that the MySQL PHP module shows
up in the phpinfo() page. 






-- 
Edit this bug report at http://bugs.php.net/?id=45338&edit=1



#45338 [NEW]: PHP 5.2.6 does not connect to MySQL

2008-06-23 Thread tpeterson at americaschoice dot org
From: tpeterson at americaschoice dot org
Operating system: Windows NT
PHP version:  5.2.6
PHP Bug Type: *Configuration Issues
Bug description:  PHP 5.2.6 does not connect to MySQL

Description:

I have installed Apache 2.2.9, PHP 5.2.6, and MySQL 5.0 on Windows. PHP
and Apache work. PHP and MySQL do not. But, MySQL does work on its own. 

I used the PHP installer for php.net downloads page. 

I keep getting the Fatal error: Call to undefined function mysql_connect()
in C:\Program Files\Apache Software
Foundation\Apache2.2\htdocs\processex.php on line 15 error when I try to
connect to my MySQL database from a PHP script.

I did the following:
1) Installed Apache, PHP, and MySQL
2) Ensured that I can run a PHP with built-in functions and display it in
my browser with Apache serving it up.
3) Log into MySQL and create a database.
4) Located the extensions path my php.ini file and ensured that my .dlls
were in it
5) Located the mysql extension statements in the php.ini file and
uncommented them (removed the semicolon before each of them EVEN THOUGH THE
MYSQL ONES WERE ALREADY UNCOMMENTED IN THIS DOWNLOAD ALTHOUGH YOU SAY THERE
IS NOT BUILT IN SUPPORT).
6) Ensured that both PHP and MySQL have entries in the System Path. 
7) Restarted the server
8) Restarted my computer. 

I got the same error. I looked at the phpinfo() and used
get_loaded_extensions() function output but saw that mysql is not
installed.

Then I did what the documentation in several places on the internet said
to do:
I deleted all the libmysql.dll and php_mysql.dll files except the ones in
the php directory and then copied them to the windows/system32 directory
and restarted my computer. I still get the same error message. Still do not
see mysql installed with the phpinfo() or get_loaded_extensions(). 

I then did the following, which is what another user suggested:
Download the PHP zip distribution and copy the .dlls out of that into my
php directory that the installer installed. No luck. I still get the same
error message.Still do not see mysql installed with the phpinfo() or
get_loaded_extensions(). 

I also tried to load php_mysql.dll with the dl() function but no luck as I
am using a multi-threaded server. 

Someone on the internet said to try deleting the php_mysql.dll and
libmysql.dll and using the ones from MySQL. I just checked and mysql is
only offering mysqli and a replacement for libmysql which I do not want to
get into just yet. 

I can get this installed (WAMP) and working if I use, for example, xampp.
So this tells me there is something wrong with your PHP code/documentation.


I am not the only one who has tried. I was teaching a class and all the
students tried individually at school and at home with no luck. I tried
this on my Windows XP and Windows NT laptops. Nothing. 


Reproduce code:
---
// we connect to example.com and port 3307
$link = mysql_connect('localhost', 'root', 'password');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);

Expected result:

That I get "Connected successfully" and that the MySQL PHP module shows up
in the phpinfo() page. 


-- 
Edit bug report at http://bugs.php.net/?id=45338&edit=1
-- 
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=45338&r=trysnapshot52
Try a CVS snapshot (PHP 5.3): 
http://bugs.php.net/fix.php?id=45338&r=trysnapshot53
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=45338&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=45338&r=fixedcvs
Fixed in release: 
http://bugs.php.net/fix.php?id=45338&r=alreadyfixed
Need backtrace:   http://bugs.php.net/fix.php?id=45338&r=needtrace
Need Reproduce Script:http://bugs.php.net/fix.php?id=45338&r=needscript
Try newer version:http://bugs.php.net/fix.php?id=45338&r=oldversion
Not developer issue:  http://bugs.php.net/fix.php?id=45338&r=support
Expected behavior:http://bugs.php.net/fix.php?id=45338&r=notwrong
Not enough info:  
http://bugs.php.net/fix.php?id=45338&r=notenoughinfo
Submitted twice:  
http://bugs.php.net/fix.php?id=45338&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=45338&r=globals
PHP 4 support discontinued:   http://bugs.php.net/fix.php?id=45338&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=45338&r=dst
IIS Stability:http://bugs.php.net/fix.php?id=45338&r=isapi
Install GNU Sed:  http://bugs.php.net/fix.php?id=45338&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=45338&r=float
No Zend Extensions:   http://bugs.php.net/fix.php?id=45338&r=nozend
MySQL Configuration Error:http://bugs.php.net/fix.php?id=45338&r=mysqlcfg