I just learned about a cool function -- "mysql_insert_id()".
You can read about it in the manual, but it sounds like it could be used
to get the AUTO_INCREMENT number from the database and you can then
append that number to your uploaded image file name.
Erik
On Thursday, January 24, 2002, a
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
says...
> I did that with this script and it works fine, but the reason I am doing it
> is so I can then give the image which is uploaded the story ID. But for some
> reason I can't get it to work... here is the auto_increment script any ideas
> o
PROTECTED]>
> Sent: Thursday, January 24, 2002 1:43 PM
> Subject: [PHP] Increment help..please
>
>
>> please help I'm a newb and this is really messing with my head. All I want
>> to know is what do I need to add to this script to allow it to increment
> the
>
ED]>
Sent: Thursday, January 24, 2002 2:43 PM
Subject: [PHP] Increment help..please
> please help I'm a newb and this is really messing with my head. All I want
> to know is what do I need to add to this script to allow it to increment
the
> ID number. pleasee.
> thank you
In your database, make the ID column AUTO_INCREMENT, and then simply don't
specify a value for it when you insert.
- Original Message -
From: "will hives" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 24, 2002 11:43 AM
Subject: [
Why don't you just set auto_increment on the id field in the database table?
Tyler
- Original Message -
From: "will hives" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 24, 2002 1:43 PM
Subject: [PHP] Increment help..please
> plea
please help I'm a newb and this is really messing with my head. All I want
to know is what do I need to add to this script to allow it to increment the
ID number. pleasee.
thank you very much for a simple boy
Will
my contact management system: add a contact
Name & ema
7 matches
Mail list logo