the idea is to have a function or a page that can be called anywhere on the website where an error happened.
the page will have a MySQL query that inserts the error info in a DB, like; place, time, type,,
How can I call/send info to the query from other pages without the user noticing, like refreshing or leaving the page.
for example, is it possible to call a PHP function with JS? or I have to do it with AJAX?
been looking for what best practice for this situation, and no luck, probably my bad search. please help with any ideas or solutions.
question from:
https://stackoverflow.com/questions/65647288/php-query-to-save-errors-how-to-run-the-page-from-other-pages-without-refreshin 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…