Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Yes, it is possible to update a Django table from a MySQL query without having to refresh the entire page by using asynchronous requests with AJAX. With AJAX, you can send a request to the Django view function that will update the database using the MySQL query and return a response without refreshing the page. This can be done by adding an event listener to an HTML element which sends an XMLHttpRequest to the Django view function when triggered. The view function can then update the table in the Django models, and return a JSON response that can be processed by the client-side JavaScript to update the data on the page.