Re: Re[2]: [PHP-DB] Table locking

2004-07-15 Thread emre erdogan
Hi... I want to say some words about the Table Locking problem. I had a problem something like this one, I find solution for this by locking only the item that will updated. I added two areas one that has a value 0 or 1 giving it is currently used by someone, and second time it is started to

Re: Re[2]: [PHP-DB] Table locking

2004-07-15 Thread Tim Van Wassenhove
In article [EMAIL PROTECTED], Emre Erdogan wrote: Hi... I want to say some words about the Table Locking problem. I had a problem something like this one, I find solution for this by locking only the item that will updated. I added two areas one that has a value 0 or 1 giving it is

[PHP-DB] Re: PHP Max execution time

2004-07-15 Thread Peter Westergaard
Lisi [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I am running a script (called through a browser) that checks entries in a table one at a time. As the table has grown, the script takes longer to run than is allowed - 30 seconds. Of course, I have to ask... is there absolutely no

RE: [PHP-DB] Re: Hold System

2004-07-15 Thread Justin Palmer
Hi, Thank you, Peter and all. This has been of great help. Regards, Justin Palmer -Original Message- From: Peter Westergaard [mailto:[EMAIL PROTECTED] Sent: Thursday, July 15, 2004 6:48 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Re: Hold System In the example of Bob, Mary

Re: [PHP-DB] Restrict account access to single user

2004-07-15 Thread Pablo M. Rivas
Hello veditio, You can use sessions: http://www.php.net/manual/en/ref.session.php and pay attention to: http://www.php.net/manual/en/function.session-cache-expire.php and session.use_cookies = 0 -- Best regards, Pablo -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit:

[PHP-DB] Re: Restrict account access to single user

2004-07-15 Thread Peter Westergaard
In other words, how do we prevent two users from using the same password to access the same account at the same time? There are a few strategies I'd consider... each has plusses and minuses. 1) Lock to one IP. Keep a table with the most recent IP address, and the most recent access time. Any

[PHP-DB] LAST_INSERT_ID?????

2004-07-15 Thread NIPP, SCOTT V (SBCSI)
OK. I know that a BUNCH of people have had this question, and I have read numerous Google threads on this, but nothing really seems to point out the resolution... I have a table with the Primary Key as an auto_increment field. Once I insert a new row of data into the table I want to

Re: [PHP-DB] LAST_INSERT_ID?????

2004-07-15 Thread Justin Patrin
Try the PHP funciton mysql_insert_id(). http://us3.php.net/manual/en/function.mysql-insert-id.php On Thu, 15 Jul 2004 15:16:44 -0500, NIPP, SCOTT V (SBCSI) [EMAIL PROTECTED] wrote: OK. I know that a BUNCH of people have had this question, and I have read numerous Google threads on

RE: [PHP-DB] LAST_INSERT_ID?????

2004-07-15 Thread Hutchins, Richard
Scott, I typically use PHP's mysql_insert_id() function on a result. For example, the following snippet from a function I use: snip $result = mysql_query($sql) or die(mysql_error()); if(!$result){ $evNew = -1;//set evID to an

[PHP-DB] Re: LAST_INSERT_ID?????

2004-07-15 Thread Tim Van Wassenhove
In article [EMAIL PROTECTED], Scott V Nipp wrote: I am trying to pull the entry number to display for the user as a ticket number. I would assume that I should use the LAST_INSERT_ID function for this. Unfortunately, I am getting either failures or all zeroes for this output. I can't

Re: [PHP-DB] LAST_INSERT_ID?????

2004-07-15 Thread Justin Patrin
On Thu, 15 Jul 2004 16:25:26 -0400, Hutchins, Richard [EMAIL PROTECTED] wrote: Scott, I typically use PHP's mysql_insert_id() function on a result. For example, the following snippet from a function I use: snip $result = mysql_query($sql) or die(mysql_error());

[PHP-DB] Printing selected characters (strcnt?)

2004-07-15 Thread Vincent Jordan
I am trying to figure out how to select the first letter of from the form field print it then append by datetime. Here is an example: snip $first_name = $_POST['first_name']; $last_name = $_POST['last_name']; $name = $first_name . ' ' . $last_name $rma = ?strcnt($last_name), 1 . Datetime(?) //

RE: [PHP-DB] Printing selected characters (strcnt?)

2004-07-15 Thread Galbreath, Mark A
Isn't there a tokenizer method? Mark -Original Message- From: Vincent Jordan [mailto:[EMAIL PROTECTED] Sent: Thursday, July 15, 2004 5:31 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] Printing selected characters (strcnt?) I am trying to figure out how to select the first letter of from

Re: [PHP-DB] Printing selected characters (strcnt?)

2004-07-15 Thread Matt M.
$first_name = $_POST['first_name']; $last_name = $_POST['last_name']; $name = $first_name . ' ' . $last_name $rma = ?strcnt($last_name), 1 . Datetime(?) // takes the 1st character from $last_name and adds datetime in format of 715041200 $rma = substr ($last_name, 0 , 1).Your.Datetime; --

[PHP-DB] Ldap query problem

2004-07-15 Thread Ryan Jameson
My LDAP queries seem to have a problem with parenthesis, does anyone know how to fix this? Example... Criteria cn=Ryan Jameson* works fine returning user with cn=Ryan Jameson (MyDomain) But... Criteria cn=Ryan Jameson (MyDomain) returns nothing. :-\ Ryan -- PHP Database Mailing List

RE: [PHP-DB] Ldap query problem

2004-07-15 Thread Swan, Nicole
Do you have some code you can provide so we can get a better idea of what you're trying to do? My guess is that the filter isn't set up quite right (as in the base dn you're attaching to get the dn is not formatted correctly). What exactly are you trying to achieve? --Nicole

RE: [PHP-DB] Ldap query problem

2004-07-15 Thread Ryan Jameson \(USA\)
I found it! The parenthesis need to be escaped, which I had tried, but silly PHP went and escaped my escapes... :-\ So the criteria on the query needed to be cn=Ryan Jameson \(MyDomain\) ... I was entering the criteria via a form which PHP conveniently turned into cn=Ryan Jameson \\(MyDomain\\)

Re: [PHP-DB] Printing selected characters (strcnt?)

2004-07-15 Thread Matthew McNicol
Try this: // takes the 1st character from $last_name and adds // datetime in format of DDMMYYhhmm $rma = substr( $last_name, 0, 1) . date(dmyHi); See: aspn.activestate.com/ASPN/docs/PHP/function.substr.html uk2.php.net/date Vincent Jordan wrote: I am trying to figure out how to select the first

[PHP-DB] execut MS SQL stored proc

2004-07-15 Thread Damien Babilon
Hi All, To resolve my last prolem, I've switched of server, I'm now on a WIN2000 ox with PHP 4.8 and Apache 1.3, thanks for your reply Now I try to execute a Stored procedure on a mssql box. The connection is ok, ut I can't get the results. The stored procedure did'n return a recordset, it

[PHP-DB] execut MS SQL stored proc

2004-07-15 Thread Damien Babilon
Hi All, To resolve my last prolem, I've switched of server, I'm now on a WIN2000 ox with PHP 4.8 and Apache 1.3, thanks for your reply Now I try to execute a Stored procedure on a mssql box. The connection is ok, ut I can't get the results. The stored procedure did'n return a recordset, it

Re: [PHP-DB] Re: Restrict account access to single user

2004-07-15 Thread Miles Thompson
They are all good suggestions, Tim's is probably the most sophisticated, but it's inevitable that usernames and passwords will escape. On top of this I'd add a weekly count of user logins, so that the users in effect buy a given amount of accesses each week. If you're really serious, you will

Re: [PHP-DB] Easy reg expression problem

2004-07-15 Thread Jason Wong
On Friday 16 July 2004 08:05, Justin Patrin wrote: If you're simply trying to get '@email.com' then use strstr(). Of courseI'm just so used to pregs... Well the advantage of using a regex is that you can perform some form of validation on the address. -- Jason Wong - Gremlins

[PHP-DB] session_start

2004-07-15 Thread Steve Butzel
I have set the session.save_path (in my php.ini-recommended AND php.ini-dist file) to c:\php4\sess\tmp. I have also created those directories accordingly. However, when I try to browse a very simple .php file (see below) that includes session_start(): I am getting the following error messages:

[PHP-DB] Re: session_start

2004-07-15 Thread Peter Westergaard
Steve Butzel [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] It appears that Apache/PHP still thinks the session.save_path is /tmp, even though I changed this in php.ini-recommended and php.ini-dist. **What am I doing wrong?** Have you changed it in the version of php.ini which was

Re: [PHP-DB] session_start

2004-07-15 Thread Jason Wong
On Friday 16 July 2004 08:15, Steve Butzel wrote: It appears that Apache/PHP still thinks the session.save_path is /tmp, even though I changed this in php.ini-recommended and php.ini-dist. **What am I doing wrong?** Firstly, to see what your settings really are, use phpinfo(). Secondly, when

Re: [PHP-DB] session_start

2004-07-15 Thread John W. Holmes
Jason Wong wrote: On Friday 16 July 2004 08:15, Steve Butzel wrote: It appears that Apache/PHP still thinks the session.save_path is /tmp, even though I changed this in php.ini-recommended and php.ini-dist. **What am I doing wrong?** Firstly, to see what your settings really are, use phpinfo().