Good day dear programmers!
I have to create simple html form, and insert that values into database. (MySQL)
I have done it.
And in my other.php ---> I select all datas from table and fetch it (viewing it in the screen)
Also, no problem.
Now, I have to put EDIT and DELETE buttons near all my data,
and while pressing EDIT, I should be able to update that data directly to database.
How can I do it?
If you have ready form templates done in php, it will be useful for me.
Thanks,
Kind Regards!
2 replies to this topic
#1
Posted 03 February 2012 - 10:05 AM
|
|
|
#2
Posted 03 February 2012 - 11:17 PM
I'm not exactly sure I understand what you need help. Maybe if you posted your code it would help.
#3
Posted 04 February 2012 - 02:17 AM
If rows are displayed on other.php, you can freely place buttons or links beside each row to edit the content.
i.e.
This would appear as
It can be handled on the same page, or another page fetching $_GET['edit'] as the ID to modify and update.
If you wish for in place editing, javascript and/or AJAX (asynchronous javascript to make requests) will be necessary. There are some softwares to edit tables, however you may not find a template that just fits in.
i.e.
echo $row['data'] . " <a href='other.php?edit=" . $row['id'] . "'>[edit]</a>"; //assuming $row['id'] is the id of the specific data
This would appear as
some data [edit]
It can be handled on the same page, or another page fetching $_GET['edit'] as the ID to modify and update.
If you wish for in place editing, javascript and/or AJAX (asynchronous javascript to make requests) will be necessary. There are some softwares to edit tables, however you may not find a template that just fits in.
Be sure to read the updated FAQ! || Health is achieved through the same 10,000 steps.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.
If a suggested code/method fails, informing us is less important than telling us why or what errors occurred.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account


Back to top









