aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorrvelices <rv-github@modusoptimus.com>2006-02-11 19:36:09 +0000
committerrvelices <rv-github@modusoptimus.com>2006-02-11 19:36:09 +0000
commitc2b9863da0f560f5afb2adb01ca32431f442c352 (patch)
treedde777ad6a650b6f251541996d137136cb99faf6 /include
parent512740968f7f09b3901897416ded964f46cb5faa (diff)
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
Diffstat (limited to '')
-rw-r--r--include/functions.inc.php22
1 files changed, 5 insertions, 17 deletions
diff --git a/include/functions.inc.php b/include/functions.inc.php
index 49f1b44bd..b00d856ae 100644
--- a/include/functions.inc.php
+++ b/include/functions.inc.php
@@ -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";
}
@@ -974,20 +976,6 @@ SELECT '.$conf['user_fields']['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 ?
*
* @return array