This topic is locked

New User Registration

1/27/2006 11:18:04 AM
PHPRunner General questions
A
Alan4573 author

Hi,
I have a users table which I use for registration of new users (obviously).
Fields - ID, Name, Address, Username, Password, Registered
I want the registered field to be automatically populated with the current date/time on successful registration.
I know I should be using NOW() in there somewhere and I've tried using events - no joy.

Can anybody help me please.
Thanks
Alan

prleo1 1/27/2006

I could be wrong, but I would put the NOW() funciton for the default value of the column on Step 7.
Let me know; if not, I will look at my past projects and see if I can help.

PR

A
Alan4573 author 1/27/2006

I could be wrong, but I would put the NOW() funciton for the default value of the column on Step 7.

Let me know; if not, I will look at my past projects and see if I can help.

PR



PR
Thanks for that.
Unfortunately, that doesn't seem to work. I would imagine that would just put the current date/time in before editing the table manually.
What I want is slightly different - in essence, its the same as having a hidden field with the value of NOW() in the registration form which is inserted into the relevant field in the table.

This is relatively straightforward to achieve normally, but I haven't got a clue how to insert this into the new registration form on register.php.
EDIT: - I did it the easy way. Changed the datatype on the registered field to TIMESTAMP.....
Cheers for your response anyway
Alan