issue #2414 change single tag display

This commit is contained in:
HWFord
2025-10-07 16:47:11 +02:00
parent b6312b5015
commit 416dbe2d24
4 changed files with 24 additions and 43 deletions

View File

@@ -409,27 +409,6 @@ function get_tags_content_title()
. l10n( count($page['tags']) > 1 ? 'Tags' : 'Tag' )
. '</a> ';
for ($i=0; $i<count($page['tags']); $i++)
{
if (1 == count($page['tags']))
{
$title.=
'<a href="'
.make_index_url(
array(
'tags' => array( $page['tags'][$i] )
)
)
.'" title="'
.l10n('display photos linked to this tag')
.'">'
.trigger_change('render_tag_name', $page['tags'][$i]['name'], $page['tags'][$i])
.'</a>';
}
}
return $title;
}

View File

@@ -9,29 +9,26 @@ global $page;
$selected_related_tags_info = array();
if (count($page['tags']) > 1)
foreach ($page['tags'] as $key=>$tag)
{
foreach ($page['tags'] as $key=>$tag)
{
$other_tags = $page['tags'];
unset($other_tags[$key]);
$other_tags = $page['tags'];
unset($other_tags[$key]);
$selected_related_tags_info[$key] =
array(
'tag_name' => trigger_change('render_tag_name', $page['tags'][$key]['name'], $page['tags'][$key]),
'item_count' => '',
'index_url' => make_index_url(
array(
'tags' => array( $page['tags'][$key] )
)
),
'remove_url' => make_index_url(
array(
'tags' => $other_tags
)
$selected_related_tags_info[$key] =
array(
'tag_name' => trigger_change('render_tag_name', $page['tags'][$key]['name'], $page['tags'][$key]),
'item_count' => '',
'index_url' => make_index_url(
array(
'tags' => array( $page['tags'][$key] )
)
);
}
),
'remove_url' => make_index_url(
array(
'tags' => $other_tags
)
)
);
}
$template->assign(