mirror of
https://github.com/Piwigo/Piwigo.git
synced 2025-04-26 19:29:58 +03:00
feature 1583: (tag navigation ergonomy) in the page title, always display the
"remove tag" icon, whatever the number of tags. git-svn-id: http://piwigo.org/svn/trunk@5706 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
parent
667ebdaa28
commit
c5a5bbc079
1 changed files with 19 additions and 15 deletions
|
@ -411,25 +411,29 @@ function get_tags_content_title()
|
|||
.$page['tags'][$i]['name']
|
||||
.'</a>';
|
||||
|
||||
if ( count($page['tags'])>2 )
|
||||
$remove_url = null;
|
||||
if (count($page['tags']) == 1)
|
||||
{
|
||||
$remove_url = get_root_url().'tags.php';
|
||||
}
|
||||
else
|
||||
{
|
||||
$other_tags = $page['tags'];
|
||||
unset ( $other_tags[$i] );
|
||||
$title.=
|
||||
'<a href="'
|
||||
.make_index_url(
|
||||
array(
|
||||
'tags' => $other_tags
|
||||
)
|
||||
unset($other_tags[$i]);
|
||||
$remove_url = make_index_url(
|
||||
array(
|
||||
'tags' => $other_tags
|
||||
)
|
||||
.'" style="border:none;" title="'
|
||||
.l10n('remove this tag from the list')
|
||||
.'"><img src="'
|
||||
.get_root_url().get_themeconf('icon_dir').'/remove_s.png'
|
||||
.'" alt="x" style="vertical-align:bottom;" class="button">'
|
||||
.'</a>';
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
$title.=
|
||||
'<a href="'.$remove_url.'" style="border:none;" title="'
|
||||
.l10n('remove this tag from the list')
|
||||
.'"><img src="'
|
||||
.get_root_url().get_themeconf('icon_dir').'/remove_s.png'
|
||||
.'" alt="x" style="vertical-align:bottom;" class="button">'
|
||||
.'</a>';
|
||||
}
|
||||
return $title;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue