diff options
author | Stephen Beaver <sbeaver@netgate.com> | 2015-11-07 21:47:00 -0500 |
---|---|---|
committer | Stephen Beaver <sbeaver@netgate.com> | 2015-11-07 21:47:00 -0500 |
commit | 02e2825a852bc0cd10cf0bc38b933a03c7da0a45 (patch) | |
tree | 22277db2366d9e3e04fb9a39fbf1c6e0ba9e0738 /src/usr/local/www | |
parent | 5d36f3c4604c09e3c3856d525537aa915a2013d3 (diff) | |
download | pfsense-02e2825a852bc0cd10cf0bc38b933a03c7da0a45.zip pfsense-02e2825a852bc0cd10cf0bc38b933a03c7da0a45.tar.gz |
Fixed #5385
Diffstat (limited to 'src/usr/local/www')
-rw-r--r-- | src/usr/local/www/guiconfig.inc | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/src/usr/local/www/guiconfig.inc b/src/usr/local/www/guiconfig.inc index 77f549e..4e9e16b 100644 --- a/src/usr/local/www/guiconfig.inc +++ b/src/usr/local/www/guiconfig.inc @@ -1073,9 +1073,10 @@ function display_top_tabs(& $tab_array, $no_drop_down = false, $type = 'pills') // If the character count of the tab names is > 670 // then show a select item dropdown menubox. - if ($tabcharcount > $tab_array_char_limit): ?> + if ($tabcharcount > $tab_array_char_limit) { echo gettext("Currently viewing: "); echo "<select name=\"TabSelect\" onchange=\"tabs_will_go(this)\">\n"; + foreach ($tab_array as $ta) { if ($ta[1] == "true") $selected = " selected=\"selected\""; @@ -1085,19 +1086,27 @@ function display_top_tabs(& $tab_array, $no_drop_down = false, $type = 'pills') // echo "<option onclick=\"document.location='{$ta[2]}';\"{$selected}>{$ta['0']}</option>\n"; echo "<option value=\"{$ta[2]}\"{$selected}>{$ta['0']}</option>\n"; } + echo "</select>\n<p> </p>"; echo "<script type=\"text/javascript\">"; echo "\n//<![CDATA[\n"; echo " function tabs_will_go(obj){ document.location = obj.value; }\n"; echo "//]]>\n"; echo "</script>"; -<? else: ?> - <ul class="nav nav-<?= $type ?>"> - <?php foreach ($tab_array as $ta): ?> - <li role="presentation"<?=($ta[1] ? ' class="active"' : '')?>><a href="<?=$ta[2]?>"><?=$ta[0]?></a></li> - <?php endforeach; ?> - </ul> -<?php endif; + } else { + echo '<ul class="nav nav-' . $type . '">'; + + foreach ($tab_array as $ta) { + echo '<li role="presentation"'; + if ($ta[1]) { + echo ' class="active"'; + } + + echo '><a href="' . $ta[2] . '">' . $ta[0] . '</a></li>'; + } + + echo '</ul>'; + } } function add_package_tabs($tabgroup, &$tab_array) { |