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

Reply via email to