mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-03-28 17:42:57 +01:00
Very small corrections:
- syntax error (action.php) - language (call to l10n_dec and English language) - replace some fetch_array with fetch_assoc (less memory used) - removed one unnecessary assign_block_vars - removed meta name="robots" (conflict with notification.php) git-svn-id: http://piwigo.org/svn/trunk@1678 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -80,15 +80,15 @@ if ( empty($element_info) )
|
||||
{
|
||||
do_error(404, 'Requested id not found');
|
||||
}
|
||||
|
||||
// $filter['visible_categories'] and $filter['visible_images']
|
||||
|
||||
// $filter['visible_categories'] and $filter['visible_images']
|
||||
// are not used because it's not necessary (filter <> restriction)
|
||||
$query='
|
||||
SELECT id FROM '.CATEGORIES_TABLE.'
|
||||
INNER JOIN '.IMAGE_CATEGORY_TABLE.'
|
||||
ON category_id=id
|
||||
WHERE image_id='.$id.'
|
||||
.'get_sql_condition_FandF(array('forbidden_categories' => 'category_id'), 'AND').'
|
||||
WHERE image_id='.$id.'
|
||||
'.get_sql_condition_FandF(array('forbidden_categories' => 'category_id'), 'AND').'
|
||||
LIMIT 1
|
||||
;';
|
||||
if ( mysql_num_rows(pwg_query($query))<1 )
|
||||
|
||||
@@ -33,7 +33,7 @@ $filter = array();
|
||||
// $filter['visible_images']: List of visible images
|
||||
|
||||
|
||||
$filter['enabled'] =
|
||||
$filter['enabled'] =
|
||||
(in_array(basename($_SERVER['SCRIPT_FILENAME']), $conf['filter_pages'])) and
|
||||
(
|
||||
(isset($_GET['filter']) and ($_GET['filter'] == 'start')) or
|
||||
@@ -98,7 +98,7 @@ WHERE ';
|
||||
$filter['visible_images'] = pwg_get_session_var('filter_visible_images', '');
|
||||
}
|
||||
|
||||
$header_notes[] = l10n_dec($lang['note_filter_day'], $lang['note_filter_days'], $user['recent_period']);
|
||||
$header_notes[] = l10n_dec('note_filter_day', 'note_filter_days', $user['recent_period']);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -84,10 +84,8 @@ SELECT DISTINCT image_id
|
||||
;';
|
||||
|
||||
$result = pwg_query($tags_query);
|
||||
|
||||
$tags = array();
|
||||
|
||||
while ($row = mysql_fetch_array($result))
|
||||
while ($row = mysql_fetch_assoc($result))
|
||||
{
|
||||
array_push($tags, $row);
|
||||
}
|
||||
@@ -109,10 +107,8 @@ SELECT id AS tag_id,
|
||||
FROM '.TAGS_TABLE.'
|
||||
;';
|
||||
$result = pwg_query($query);
|
||||
|
||||
$tags = array();
|
||||
|
||||
while ($row = mysql_fetch_array($result))
|
||||
while ($row = mysql_fetch_assoc($result))
|
||||
{
|
||||
array_push($tags, $row);
|
||||
}
|
||||
@@ -269,7 +265,7 @@ SELECT tag_id, name, url_name, count(*) counter
|
||||
|
||||
$result = pwg_query($query);
|
||||
$tags = array();
|
||||
while($row = mysql_fetch_array($result))
|
||||
while($row = mysql_fetch_assoc($result))
|
||||
{
|
||||
array_push($tags, $row);
|
||||
}
|
||||
|
||||
@@ -419,7 +419,7 @@ function set_make_full_url()
|
||||
$page['save_root_path']['path'] = $page['root_path'];
|
||||
}
|
||||
$page['save_root_path']['count'] = 1;
|
||||
$page['root_path'] = 'http://'.$_SERVER['HTTP_HOST'].cookie_path();
|
||||
$page['root_path'] = get_host_url().cookie_path();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -64,7 +64,6 @@ if (isset($header_infos))
|
||||
// Header notes
|
||||
if (count($header_notes) > 0)
|
||||
{
|
||||
$template->assign_block_vars('header_notes', array());
|
||||
foreach ($header_notes as $header_note)
|
||||
{
|
||||
$template->assign_block_vars('header_notes.header_note',
|
||||
|
||||
@@ -475,8 +475,8 @@ $lang['identification'] = 'Identification';
|
||||
$lang['image_available'] = '%d image';
|
||||
$lang['images_available'] = '%d images';
|
||||
$lang['images_available_cpl'] = 'in this category';
|
||||
$lang['images_available_cat'] = 'in %d sub-catégory';
|
||||
$lang['images_available_cats'] = 'in %d sub-catégories';
|
||||
$lang['images_available_cat'] = 'in %d sub-category';
|
||||
$lang['images_available_cats'] = 'in %d sub-categories';
|
||||
$lang['included'] = 'included';
|
||||
$lang['invalid_pwd'] = 'Invalid password!';
|
||||
$lang['language']='Language';
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
<html lang="{LANG}" dir="{DIR}">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset={CONTENT_ENCODING}">
|
||||
<meta name="robots" content="index, follow">
|
||||
<meta name="generator" content="PhpWebGallery (aka PWG), see www.phpwebgallery.net">
|
||||
<!-- BEGIN header_meta -->
|
||||
<meta name="author" content="{header_meta.INFO_AUTHOR}">
|
||||
|
||||
Reference in New Issue
Block a user