MySQL SET PASSWORD Statement Syntax
The syntax for the MySQL SET PASSWORD statement to change an arbitrary user's password is as follows:
SET PASSWORD FOR 'user'@'host' = PASSWORD('newpassword');
To change your own password, the syntax is:
SET PASSWORD = PASSWORD('newpassword');
That is, to change another user's password, you will need to specify their username and hostname exactly as it is in the User and Host columns in the mysql.user table.
SELECT name, SUM(price) FROM subrequests GROUP BY request_id
$.post(
'/index.php',
{
'filed': '123',
'arr['+inp+']' // Где ключ или значение?
}
);
var input = 'text';
var params = {
field: '123',
arr: {}
};
params.arr[input] = 'хз';
$.post('/index.php', params);
$.ajax({
cache: false,
url: page,
dataType: 'html',
success: function(response) {
var $newBody = $(response).find('body');
// тут как то нужно получить <body> с его содержимым из data
$('body').prepend($newBody.html());
}
});
function sum_time()
{
$totalSeconds = 0;
foreach (func_get_args() as $time)
{
sscanf($time, '%d:%d:%d', $hours, $minutes, $seconds);
$totalSeconds += ($hours * 60 * 60) + ($minutes * 60) + $seconds;
}
$hours = floor($totalSeconds / 3600);
$minutes = floor(($totalSeconds / 60) % 60);
$seconds = $totalSeconds % 60;
return sprintf('%02d:%02d:%02d', $hours, $minutes, $seconds);
}
// use example
echo sum_time('01:05:37', '00:02:00', '05:59:59'); # 07:07:36