php update query code example
Example 1: live update mysql data in php
$(document).ready(function(){
loadstation();
});
function loadstation(){
$("#station_data").load("station.php");
setTimeout(loadstation, 2000);
}
Example 2: update php sql
$_old_username = "Randy";
$_new_username = $_POST["username"];
$_sql = "UPDATE user SET first_name = $_new_username WHERE first_name = $_old_username";