How I can start a MySQL query only when my page is fully loaded ?
I need that because my query impact much data and increase the time of load of the page for my visitor :/
I tried with this code without success =>
$(window).load(function() {
include(BASE . "sql-query.php");
?>
});
解决方案
Assuming the file where there's the query is sql-query.php, use that code (ps: remember to include jquery library!):
[into
]$(window).load(function() {
$("#query").load("sql-query.php");
});
[into
]
Loading...