mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-07-21 09:03:38 +02:00
- admin/update : filesystem synchronization process completely
rewritten. How to speed up sync ? by avoiding recursivity ! - admin/update : option to display verbose information details - admin/update : option to simulate only. No database insert, delete or update will be made - bug fixed : in admin/cat_list, if you delete a virtual category, you may create a gap in the rank list. This gap will generate errors when trying to move a category on this gap. Fixed by calling ordering and update_global_rank at category deletion. - admin/cat_list, only one query to insert a new virtual category (no need of a second query to update uppercats and global_rank) - for a given category, even if empty, the representing element must not be the one of a forbidden category for the current user - generation time optionnaly displayed on the bottom of each page becomes more price : number of SQL queries and SQL time added. git-svn-id: http://piwigo.org/svn/trunk@659 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -461,24 +461,23 @@ function pwg_write_debug()
|
||||
|
||||
function pwg_query($query)
|
||||
{
|
||||
global $conf;
|
||||
global $conf,$count_queries,$queries_time;
|
||||
|
||||
$start = get_moment();
|
||||
$result = mysql_query($query);
|
||||
|
||||
|
||||
$time = get_moment() - $start;
|
||||
$count_queries++;
|
||||
$queries_time+= $time;
|
||||
|
||||
if ($conf['show_queries'])
|
||||
{
|
||||
global $count_queries,$queries_time;
|
||||
|
||||
$time = get_moment() - $start;
|
||||
$count_queries++;
|
||||
|
||||
$output = '';
|
||||
$output.= '<pre>['.$count_queries.'] '."\n".$query;
|
||||
$queries_time+= $time;
|
||||
$output.= "\n".'(this query time : '.number_format( $time, 3, '.', ' ').' s)</b>';
|
||||
$output.= "\n".'(total SQL time : '.number_format( $queries_time, 3, '.', ' ').' s)';
|
||||
$output.= '</pre>';
|
||||
|
||||
echo $output;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user