NewbieBryan Posted July 10, 2009 Share Posted July 10, 2009 I have a requirement whereby I need to update the price on items on my site: The pricing info is held is a very basic table with just 3 items: UniqueID | Description and | Price I have created an update for which works fine by displaying a table with the above items in it On the same page there is a form where I can input the Unique ID, Updated Description and Updated Price. Hitting Sumbit updates the Db and the webpage is up to date again. Now my items are very simple: Eg 1 Brick 0.87 2 Rock 1.22 but this got me to thinking; What would happen in had a very complex description - lets say 30 or 40 words and I discovered after entering the data I had made a typo. Well, I guess I go into the backend and change the raw data but that is a bit of an overkill to what should be a simple problem. so that leaves me with 2 choices (as far as I can tell) create another form where I enter the UniqueID which in turn goes to another page with text input blocks pre-poulated from the database (value = fromdB) or and this is the part where my logic is failing me and I need some help When I create my table I would like to dynamically include a 4th column with the choice EDIT If I push EDIT this would then take me to a page/section where the Description and price fields are prepopulated and all I would have to do is make the relevant (hopefully small change) - hit submit and update the db. Any advice on how to go about this would be greatly appretiated. Tx Bryan Link to comment https://forums.phpfreaks.com/topic/165547-self-populating-updated-form-logic-help-needed/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.