[2.0.14] Theme selection page displays ";vrt=X" if theme has selectable variants

Started by Dav999, July 11, 2017, 11:06:23 AM

Previous topic - Next topic


If a theme has selectable variants (for example Golove, or my modified testing version of Core in the image below), the displayed name of the theme contains ;vrt=(name) on the theme selection page, which seems to have accidentally been added to the link text instead of the link:

The cause can be found on this line in Themes.template.php:
<a href="', $scripturl, '?action=theme;sa=pick;u=', $context['current_member'], ';th=', $theme['id'], ';', $context['session_var'], '=', $context['session_id'], '">', $theme['name'], (!empty($theme['variants']) ? ';vrt=' . $theme['selected_variant'] : ''), '</a>

I'm guessing it should have been this instead:
<a href="', $scripturl, '?action=theme;sa=pick;u=', $context['current_member'], ';th=', $theme['id'], ';', $context['session_var'], '=', $context['session_id'], (!empty($theme['variants']) ? ';vrt=' . $theme['selected_variant'] : ''), '">', $theme['name'], '</a>