mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-07-21 00:53:04 +02:00
remake Remote Site/Synchro - bug on commentable + use l10n instead of get_lang
git-svn-id: http://piwigo.org/svn/trunk@1033 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -430,7 +430,7 @@ function format_date($date, $type = 'us', $show_time = false)
|
||||
|
||||
function pwg_query($query)
|
||||
{
|
||||
global $conf,$page,$debug;
|
||||
global $conf,$page,$debug,$t2;
|
||||
|
||||
$start = get_moment();
|
||||
$result = mysql_query($query) or my_error($query."\n");
|
||||
@@ -455,6 +455,8 @@ function pwg_query($query)
|
||||
$output.= '<b>'.number_format($time, 3, '.', ' ').' s)</b>';
|
||||
$output.= "\n".'(total SQL time : ';
|
||||
$output.= number_format($page['queries_time'], 3, '.', ' ').' s)';
|
||||
$output.= "\n".'(total time : ';
|
||||
$output.= number_format( ($time+$start-$t2), 3, '.', ' ').' s)';
|
||||
$output.= "</pre>\n";
|
||||
|
||||
$debug .= $output;
|
||||
@@ -465,7 +467,7 @@ function pwg_query($query)
|
||||
|
||||
function pwg_debug( $string )
|
||||
{
|
||||
global $debug,$t2,$count_queries;
|
||||
global $debug,$t2,$page;
|
||||
|
||||
$now = explode( ' ', microtime() );
|
||||
$now2 = explode( '.', $now[0] );
|
||||
@@ -473,7 +475,7 @@ function pwg_debug( $string )
|
||||
$time = number_format( $now2 - $t2, 3, '.', ' ').' s';
|
||||
$debug .= '<p>';
|
||||
$debug.= '['.$time.', ';
|
||||
$debug.= $count_queries.' queries] : '.$string;
|
||||
$debug.= $page['count_queries'].' queries] : '.$string;
|
||||
$debug.= "</p>\n";
|
||||
}
|
||||
|
||||
@@ -973,20 +975,6 @@ SELECT '.$conf['user_fields']['email'].'
|
||||
return $email;
|
||||
}
|
||||
|
||||
/**
|
||||
* returns the $str in current language if possible or $str enclosed
|
||||
* in special chars
|
||||
*/
|
||||
function get_lang($str)
|
||||
{
|
||||
global $lang;
|
||||
if ( isset($lang[$str]) )
|
||||
{
|
||||
return $lang[$str];
|
||||
}
|
||||
return '@@'.$str.'@@';
|
||||
}
|
||||
|
||||
/**
|
||||
* which upgrades are available ?
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user