aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/styles
diff options
context:
space:
mode:
authorVjacheslav Trushkin <cyberalien@gmail.com>2013-05-23 12:18:06 +0300
committerVjacheslav Trushkin <cyberalien@gmail.com>2013-08-30 14:52:45 +0300
commit2624d1ea149eb6582020e90d1ceebf99e45a73f9 (patch)
treee234c6dd05f143f7d3ce14c4db85471aa3e6fa0e /phpBB/styles
parentd091c4f829daae48cc60f735b10c24f666959520 (diff)
downloadforums-2624d1ea149eb6582020e90d1ceebf99e45a73f9.tar
forums-2624d1ea149eb6582020e90d1ceebf99e45a73f9.tar.gz
forums-2624d1ea149eb6582020e90d1ceebf99e45a73f9.tar.bz2
forums-2624d1ea149eb6582020e90d1ceebf99e45a73f9.tar.xz
forums-2624d1ea149eb6582020e90d1ceebf99e45a73f9.zip
[ticket/11562] Use jQuery in subPanels
PHPBB-11562
Diffstat (limited to 'phpBB/styles')
-rw-r--r--phpBB/styles/prosilver/template/forum_fn.js20
1 files changed, 3 insertions, 17 deletions
diff --git a/phpBB/styles/prosilver/template/forum_fn.js b/phpBB/styles/prosilver/template/forum_fn.js
index 65bc3dedb7..4fb8f7b284 100644
--- a/phpBB/styles/prosilver/template/forum_fn.js
+++ b/phpBB/styles/prosilver/template/forum_fn.js
@@ -117,29 +117,15 @@ jQuery(document).ready(function() {
}
function subPanels(p) {
- var i, e, t;
+ var i;
if (typeof(p) === 'string') {
show_panel = p;
}
for (i = 0; i < panels.length; i++) {
- e = document.getElementById(panels[i]);
- t = document.getElementById(panels[i] + '-tab');
-
- if (e) {
- if (panels[i] === show_panel) {
- e.style.display = 'block';
- if (t) {
- t.className = 'activetab';
- }
- } else {
- e.style.display = 'none';
- if (t) {
- t.className = '';
- }
- }
- }
+ jQuery('#' + panels[i]).css('display', panels[i] === show_panel ? 'block' : 'none');
+ jQuery('#' + panels[i] + '-tab').toggleClass('activetab', panels[i] === show_panel);
}
}
});