summaryrefslogtreecommitdiff
path: root/templates/themes
diff options
context:
space:
mode:
authorMichael D. Reiley <mreiley@omegasdg.com>2011-09-22 15:07:25 -0700
committerMichael D. Reiley <mreiley@omegasdg.com>2011-09-22 15:07:25 -0700
commita59b915b0a94fe621503deeeca5eef17c5fababc (patch)
treef5492d09513fdd0d5761eddcfb9793275aeca201 /templates/themes
parentc210cdbfea79834873a78f114f5c33e161cfe140 (diff)
Categories theme v0.2.1 (Frame removal works correctly.)
Diffstat (limited to 'templates/themes')
-rw-r--r--templates/themes/categories/info.php2
-rw-r--r--templates/themes/categories/theme.php12
2 files changed, 7 insertions, 7 deletions
diff --git a/templates/themes/categories/info.php b/templates/themes/categories/info.php
index 3718344c..0090f39d 100644
--- a/templates/themes/categories/info.php
+++ b/templates/themes/categories/info.php
@@ -8,7 +8,7 @@
'Group-ordered, category-aware modification of the Frameset theme, with removable sidebar frame.
Requires $config[\'boards\'] and $config[\'categories\'].';
- $theme['version'] = 'v0.2';
+ $theme['version'] = 'v0.2.1';
// Theme configuration
$theme['config'] = Array();
diff --git a/templates/themes/categories/theme.php b/templates/themes/categories/theme.php
index 393ad5bd..de1b4a5b 100644
--- a/templates/themes/categories/theme.php
+++ b/templates/themes/categories/theme.php
@@ -39,6 +39,11 @@
. 'iframe#main{border-left:1px solid black;left:15%;top:0;width:85%}'
. '</style>'
. '<title>' . $settings['title'] . '</title>'
+ . '<script type="text/javascript">'
+ . 'function removeFrames() {'
+ . 'window.location = document.getElementById("main").contentWindow.location.href'
+ . '}'
+ . '</script>'
. '</head><body>'
// Sidebar
. '<iframe src="sidebar.html" id="sidebar" name="sidebar"></iframe>'
@@ -109,16 +114,11 @@
. '</style>'
. '<base target="main" />'
. '<title>' . $settings['title'] . '</title>'
- . '<script type="text/javascript">'
- . 'function removeFrames() {'
- . 'parent.window.location = "' . $config['root'] . 'news.html"'
- . '}'
- . '</script>'
. '</head><body>';
$body .= '<fieldset><legend>' . $settings['title'] . '</legend><ul>' .
'<li><a class="system" href="news.html">[News]</a></li>' .
- '<li><a class="system" href="javascript:removeFrames()">[Remove Frames]</a></li>' .
+ '<li><a class="system" href="javascript:parent.removeFrames()">[Remove Frames]</a></li>' .
'</ul></fieldset>';
for($cat = 0; $cat < count($config['categories']); $cat++) {