[PHP] mysql.lock file location

2003-09-25 Thread Donald Tyler
Hi,

 

Does anyone know how to tell PHP to look in a different location for the
mysql.lock file? It's currently looking in /tmp/ and that's wrong.

 

 

Thanks

 

 

Donald



Re: [PHP] mysql.lock file location

2003-09-25 Thread Jason Wong
On Thursday 25 September 2003 21:17, Donald Tyler wrote:

 Does anyone know how to tell PHP to look in a different location for the
 mysql.lock file? It's currently looking in /tmp/ and that's wrong.

manual  MySQL Functions

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Oh, give me a home,
Where the buffalo roam,
And I'll show you a house with a really messy kitchen.
*/

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



RE: [PHP] mysql.lock file location

2003-09-25 Thread Donald Tyler
The MySQL functions only allow me to change the location per function
call.

I want to change the default mysql.sock file location for PHP, it would
seem silly to change every script to do that, especially since this is
only a test server and the main server will most likely have the
mysql.sock file in another location.

-Original Message-
From: Jason Wong [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 25, 2003 8:26 AM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] mysql.lock file location

On Thursday 25 September 2003 21:17, Donald Tyler wrote:

 Does anyone know how to tell PHP to look in a different location for
the
 mysql.lock file? It's currently looking in /tmp/ and that's wrong.

manual  MySQL Functions

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Oh, give me a home,
Where the buffalo roam,
And I'll show you a house with a really messy kitchen.
*/

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

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



Re: [PHP] mysql.lock file location

2003-09-25 Thread Jason Wong
On Thursday 25 September 2003 22:07, Donald Tyler wrote:
 The MySQL functions only allow me to change the location per function
 call.

 I want to change the default mysql.sock file location for PHP, it would
 seem silly to change every script to do that, especially since this is
 only a test server and the main server will most likely have the
 mysql.sock file in another location.

That section of the manual contains a useful little table which shows what 
MySQL related parameters can be changed and where it can be changed.

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Facts are the enemy of truth.
-- Don Quixote
*/

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



RE: [PHP] mysql.lock file location

2003-09-25 Thread Donald Tyler
Yeah I do that too. But I was reluctant to do that with something that
just seemed like a fix for a problem that shouldn’t even exist.

If the server with my scripts is configured correctly, then I should
never have to specify a .sock file. I hope...

-Original Message-
From: Jackson Miller [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 25, 2003 10:15 AM
To: Donald Tyler
Subject: Re: [PHP] mysql.lock file location

On Thursday 25 September 2003 8:55, you wrote:
 Is there no way for me to change the default location for PHP? I have
 quite a few scripts that I really don’t want to have to do that to. I
 would rather reconfigure PHP.
You can set default mysql settings in php.ini which allows you to set a
socket 
file.  Then you leave the default settings out of mysql_connect all
together.  
I _think_ that you can then connect with 
mysql_connect(localhost,username,password) and it will use the
socket 
file set in php.ini.

If that doesn't work you can try editing the client section of
/etc/my.cnf

Also, I always set up my apps in a way that the db connection is only in
one 
place and just called from all the scripts that need it.  You can do
this 
with an include or using object oriented coding.  This way if you ever
have 
to make a system wide change you don't have to go to all the scripts and

change it.

Hope that helps.

-Jackson

 -Original Message-
 From: Jackson Miller [mailto:[EMAIL PROTECTED]
 Sent: Thursday, September 25, 2003 8:24 AM
 To: Donald Tyler
 Subject: Re: [PHP] mysql.lock file location

 On Thursday 25 September 2003 8:17, Donald Tyler wrote:
  Hi,
 
  Does anyone know how to tell PHP to look in a different location for

 the

  mysql.lock file? It's currently looking in /tmp/ and that's wrong.

 mysql_connect(:/path/to/mysql.lock,username,password);

 -Jackson

  Thanks
 
 
 
 
 
  Donald

-- 
jackson miller
 
cold feet creative
615.321.3300 / 800.595.4401
[EMAIL PROTECTED]
 
 
cold feet presents Emma
the world's easiest email marketing
Learn more @  http://www.myemma.com

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