Re: [PHP-DB] Move from PHP4 to PHP5 , and to Zend Platform - any gotchas? (MYSQL and SQL SERVER)

2008-12-11 Thread Gunawan

i don't know about the sql.. but i have some story.
in php4, when type url like this
localhost/mywork/index.php?myid=1
i able to print the 'myid' variable easyly.. but when in php5.. i must type
$_GET['myid'] to have myid value.

Weaver Hickerson wrote:

Greetings list.  We are planning to move our legacy php4/apache system to 
PHP5 and also move to the Zend Platform.  Wondering if anyone has any gotchas/horror 
stories..  The system interfaces with both MySQL and SQL Server.

Any thoughts appreciated!


Weaver Hickerson, President
LightSpeed Technology Group
[EMAIL PROTECTED]
770-787-0880 ext 3011

  



--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] MySQLDump through PHP/HTML UI

2008-12-11 Thread phphelp -- kbk

Hi, Rick - - -

Well, there really is not a lot to tell. Yes, it is being prompted by  
a HTML page. I show the table names with checkboxes or an all.


As a result, I build the simplest 'dump statement;
  mysqldump databasenamepath/outfilename,sql --tables -- 
user=dunknob --password=doorknob


Anyway, it did turn out to be a permissions problem, so marked this  
one with a big SOLVED. it didn't smell like one, however, as the file  
was being written, the dump' heading lines were there, just the  
parameters were ignored.


Ah, well 

Thanks for your suggestions.

Ken


On Dec 10, 2008, at 9:42 PM, lists-php wrote:


you don't give a lot of information of how you are running your
utility, but you're likely to run into file permission issues in a
linux context that you won't have in a windoz one.

if you're running it through a web page you'll be trying to write
the dump file as the user that your web server runs under (by
default apache). generally (and in a secure setup) that user will
not have the ability to write to files under the documentroot.


  - Rick

 Original Message 

Date: Wednesday, December 10, 2008 09:25:37 PM -0600
From: phphelp -- kbk phph...@comcast.net
To: php-db@lists.php.net
Subject: Re: [PHP-DB] MySQLDump through PHP/HTML UI

Hi, Chris -- -- -- --

Yes, thanks for the suggestion: it runs from the command line just
fine. I run them often, and it works in Windows.

However, I just was able to gain access again to the error log
(long story), and I see that the page is throwing an unrelated
error that it does not throw in Windows. I will run down that road
and see if that error is somehow getting in the way.

Thank you for your ideas.

Ken

On Dec 10, 2008, at 3:50 PM, Chris wrote:


phphelp -- kbk wrote:

Hello - - -- -
I have a utility which creates a MySQLDump of selected tables or
 the whole database.  This works fine on my development machine,
a   W2K box. It does not work on the testing server, a linux box.
I'll post code if you want, but it is very simple:
1. I create the dump language, including the file into which
the   data is dumped into a variable.
2. I perform system($dump_language). I also tried it exec
($dump_language). Both produce the same result:


What cmd are you putting together (I assume something for
mysqldump)? If you run it manually from the cmd line, does it
work?   Does it give an error?

--
Postgresql  php tutorials
http://www.designmagick.com/


 End Original Message 





--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] Move from PHP4 to PHP5 , and to Zend Platform - any gotchas? (MYSQL and SQL SERVER)

2008-12-11 Thread Micah Gersten
That is due to register_globals being on by default in PHP4 and off by
default in PHP5.  It is a security risk and should not be used.  I
believed it is being removed in PHP 6.

Thank you,
Micah Gersten
onShore Networks
Internal Developer
http://www.onshore.com

Gunawan wrote:
 i don't know about the sql.. but i have some story.
 in php4, when type url like this
 localhost/mywork/index.php?myid=1
 i able to print the 'myid' variable easyly.. but when in php5.. i must
 type
 $_GET['myid'] to have myid value.

 Weaver Hickerson wrote:
 Greetings list.  We are planning to move our legacy php4/apache
 system to PHP5 and also move to the Zend Platform.  Wondering if
 anyone has any gotchas/horror stories..  The system interfaces with
 both MySQL and SQL Server.

 Any thoughts appreciated!

 
 Weaver Hickerson, President
 LightSpeed Technology Group
 wdhic...@lightspeedinc.com
 770-787-0880 ext 3011

   



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-DB] php crashes on mysql_connect

2008-12-11 Thread Peter Degen-Portnoy
Hi Folks,

I've been banging against this for a while and have narrowed it down to a
completely repeatable and tiny test case.

The issue is that any mysql_connect call hangs and causes a segmentation
fault in php5ts.dll.  Here are the specifics:

I am running on Windows XP, SP2, Single Athlon 64 3200+ CPU.  I have
recently installed the following:

MySQL version 5.1.30 for Win32
Apache version 2.2.10 for Win32
PHP 5.2.8

I have tried both the zip file and the msi installer to install PHP, more
recently the MSI installer.  I added the GD, mysql, mysqli and multi-byte
string extensions.

I have configured Apache  MySQL and have created some databases, which I
can access through mysql and Navicat.  I have used a simple phpinfo.php
script to track down an incorrect libmysql.dll in my path and have
eliminated that and have verified that the client version of libmysql is
5.1.30 in phpinfo.

I have a tiny script to test the mysql connectivity from php:

?php
mysql_connect('localhost', 'root', 'root');
print('Past mysql_connect');
?

but if I run this through apache, httpd.exe crashes with the following error
(recorded in the application event log)

Faulting application httpd.exe, version 2.2.10.0, faulting module
php5ts.dll, version 5.2.8.8, fault address 0xac5a.

And if I run it from the command line with

c:\php -f test_db_connection.php

I get a very similar error in the application event log:

Faulting application php.exe, version 5.2.8.8, faulting module php5ts.dll,
version 5.2.8.8, fault address 0xac5a.

I've not been able to get a backtrace for the crash and I don't have a
debugger into which I can build and put php.

I would greatly appreciate some ideas on how I can figure out where the
problem lies.  I belive that I have narrowed the problem down to a very
straight database connection issue and was pretty certain that it had to do
with an old libmysql.dll on my path, until I tracked the bugger down and
eliminated it, but to no avail.

Thanks in advance for your thoughts.

Yours,

Peter


Re: [PHP-DB] php crashes on mysql_connect

2008-12-11 Thread Chris

Peter Degen-Portnoy wrote:

Hi Folks,

I've been banging against this for a while and have narrowed it down to a
completely repeatable and tiny test case.


http://bugs.php.net/

Best place to post it and get it fixed.

--
Postgresql  php tutorials
http://www.designmagick.com/


--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] php crashes on mysql_connect

2008-12-11 Thread Peter Degen-Portnoy
Thanks, Chris.

- Peter

On Fri, Dec 12, 2008 at 1:10 AM, Chris dmag...@gmail.com wrote:

 Peter Degen-Portnoy wrote:

 Hi Folks,

 I've been banging against this for a while and have narrowed it down to a
 completely repeatable and tiny test case.


 http://bugs.php.net/

 Best place to post it and get it fixed.

 --
 Postgresql  php tutorials
 http://www.designmagick.com/