Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
June 2, 2005, 11:34 pm
rate this thread
I'm fairly new to developing PHP / MySQL databases. I've just created a
job posting board that works OK, but I want this feature: user creates
their username/password to enter a listing. Once they've entered a job
listing, they can login again and will be able to edit / drop their
listing only. Any pointers in the right direction would be appreciated.
- Samuel (lets dot monroe at gma
June 3, 2005, 8:11 am
Re: user login can edit their record only - PHP / MySQL
Too broad a question, my friend. The answer would be "you need to read
a little about db design and how it applies to php projects".
Basically, if you for example have two MySql tables, one of them with
the user data and another with their listings data (assuming one user
can have more than one of these "listings"), you need a way to identify
wich listing/s belong to wich user/s. Usually this wil be a field in
the listings table containing the name (or any other handle/key you
have assigned to the users) of its corresponding user.