need some help with editing datase entries via a form

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
belovedone
Forum Newbie
Posts: 3
Joined: Fri Oct 10, 2003 6:25 pm

need some help with editing datase entries via a form

Post by belovedone »

How would I go about editing a row in a database via a form? I know how to get the information in the text boxes. But what i would like to do is list all the rows in the database and then if i see that one of the rows needs editing or deleting i'll have 2 links under each entry (edit and delete)...and when i click "edit" it would open up a new page with a form with all the info in each text box so i can edit and then re-submit it...
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

you need a field with an unique value (e.g. an auto-increment primary index). Ship the value of the record that is to be edited/deleted with the request and use it in the sql's WHERE-clause
Post Reply