Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F223474
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
11 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/plugins/help/help.php b/plugins/help/help.php
index 66c4256a0..ab665d0a8 100644
--- a/plugins/help/help.php
+++ b/plugins/help/help.php
@@ -1,131 +1,132 @@
<?php
/**
* Roundcube Help Plugin
*
* @author Aleksander 'A.L.E.C' Machniak
* @author Thomas Bruederli <thomas@roundcube.net>
* @license GNU GPLv3+
*
* Configuration (see config.inc.php.dist)
*
**/
class help extends rcube_plugin
{
// all task excluding 'login' and 'logout'
public $task = '?(?!login|logout).*';
// we've got no ajax handlers
public $noajax = true;
// skip frames
public $noframe = true;
function init()
{
$this->load_config();
$this->add_texts('localization/', false);
// register task
$this->register_task('help');
// register actions
$this->register_action('index', array($this, 'action'));
$this->register_action('about', array($this, 'action'));
$this->register_action('license', array($this, 'action'));
$rcmail = rcmail::get_instance();
// add taskbar button
$this->add_button(array(
'command' => 'help',
'class' => 'button-help',
'classsel' => 'button-help button-selected',
'innerclass' => 'button-inner',
'label' => 'help.help',
), 'taskbar');
$this->include_script('help.js');
$rcmail->output->set_env('help_open_extwin', $rcmail->config->get('help_open_extwin', false), true);
// add style for taskbar button (must be here) and Help UI
$skin_path = $this->local_skin_path();
if (is_file($this->home . "/$skin_path/help.css")) {
$this->include_stylesheet("$skin_path/help.css");
}
}
function action()
{
$rcmail = rcmail::get_instance();
// register UI objects
$rcmail->output->add_handlers(array(
'helpcontent' => array($this, 'content'),
));
if ($rcmail->action == 'about')
$rcmail->output->set_pagetitle($this->gettext('about'));
else if ($rcmail->action == 'license')
$rcmail->output->set_pagetitle($this->gettext('license'));
else
$rcmail->output->set_pagetitle($this->gettext('help'));
$rcmail->output->send('help.help');
}
function content($attrib)
{
$rcmail = rcmail::get_instance();
switch ($rcmail->action) {
case 'about':
if (is_readable($this->home . '/content/about.html')) {
return @file_get_contents($this->home . '/content/about.html');
}
- $src = $rcmail->config->get('help_about_url', $rcmail->url(array('_task' => 'settings', '_action' => 'about')));
+ $default = $rcmail->url(array('_task' => 'settings', '_action' => 'about', '_framed' => 1));
+ $src = $rcmail->config->get('help_about_url', $default);
break;
case 'license':
if (is_readable($this->home . '/content/license.html')) {
return @file_get_contents($this->home . '/content/license.html');
}
$src = $rcmail->config->get('help_license_url', 'http://www.gnu.org/licenses/gpl-3.0-standalone.html');
break;
default:
$src = $rcmail->config->get('help_source');
// resolve task/action for depp linking
$index_map = $rcmail->config->get('help_index_map', array());
$rel = $_REQUEST['_rel'];
list($task,$action) = explode('/', $rel);
if ($add = $index_map[$rel])
$src .= $add;
else if ($add = $index_map[$task])
$src .= $add;
break;
}
// default content: iframe
if (!empty($src)) {
$attrib['src'] = $this->resolve_language($src);
}
if (empty($attrib['id']))
$attrib['id'] = 'rcmailhelpcontent';
$attrib['name'] = $attrib['id'];
return $rcmail->output->frame($attrib);
}
private function resolve_language($path)
{
// resolve language placeholder
$rcmail = rcmail::get_instance();
$langmap = $rcmail->config->get('help_language_map', array('*' => 'en_US'));
$lang = !empty($langmap[$_SESSION['language']]) ? $langmap[$_SESSION['language']] : $langmap['*'];
return str_replace('%l', $lang, $path);
}
}
diff --git a/plugins/help/skins/classic/help.css b/plugins/help/skins/classic/help.css
index 8f67f111e..ad5b7dab4 100644
--- a/plugins/help/skins/classic/help.css
+++ b/plugins/help/skins/classic/help.css
@@ -1,29 +1,29 @@
/***** Roundcube|Mail Help task styles *****/
#taskbar a.button-help
{
background-image: url('help.gif');
}
.help-box
{
- overflow: auto;
+ overflow: auto;
background-color: #F2F2F2;
}
#helplicense, #helpabout
{
width: 46em;
padding: 1em 2em;
}
#helplicense a, #helpabout a
{
color: #900;
}
#helpabout
{
margin: 0 auto;
}
diff --git a/plugins/help/skins/classic/templates/help.html b/plugins/help/skins/classic/templates/help.html
index 8a398e7b3..5bc342044 100644
--- a/plugins/help/skins/classic/templates/help.html
+++ b/plugins/help/skins/classic/templates/help.html
@@ -1,36 +1,36 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><roundcube:object name="pagetitle" /></title>
<roundcube:include file="/includes/links.html" />
<link rel="stylesheet" type="text/css" href="/this/help.css" />
<script type="text/javascript">
function help_init_settings_tabs()
{
- var action, tab = '#helptabdefault';
+ var action, tab = '#helptabindex';
if (window.rcmail && (action = rcmail.env.action)) {
- tab = '#helptab' + (action ? action : 'default');
+ tab = '#helptab' + (action ? action : 'index');
}
$(tab).addClass('tablink-selected');
}
</script>
</head>
<roundcube:if condition="env:extwin" /><body class="extwin"><roundcube:else /><body><roundcube:endif />
<roundcube:include file="/includes/taskbar.html" />
<roundcube:include file="/includes/header.html" />
<div id="tabsbar">
-<span id="helptabdefault" class="tablink"><roundcube:button name="helpdefault" href="?_task=help" type="link" label="help.help" title="help.help" /></span>
+<span id="helptabindex" class="tablink"><roundcube:button name="helpindex" href="?_task=help" type="link" label="help.help" title="help.help" /></span>
<span id="helptababout" class="tablink"><roundcube:button name="helpabout" href="?_task=help&_action=about" type="link" label="help.about" title="help.about" class="tablink" /></span>
<span id="helptablicense" class="tablink"><roundcube:button name="helplicense" href="?_task=help&_action=license" type="link" label="help.license" title="help.license" class="tablink" /></span>
<roundcube:container name="helptabs" id="helptabsbar" />
<script type="text/javascript"> if (window.rcmail) rcmail.add_onload(help_init_settings_tabs);</script>
</div>
<div id="mainscreen" class="box help-box">
<roundcube:object name="helpcontent" id="helpcontentframe" width="100%" height="100%" frameborder="0" src="/watermark.html" />
</div>
</body>
</html>
diff --git a/plugins/help/skins/larry/help.css b/plugins/help/skins/larry/help.css
index c2e369af6..d9af6e15e 100644
--- a/plugins/help/skins/larry/help.css
+++ b/plugins/help/skins/larry/help.css
@@ -1,45 +1,44 @@
#helpcontentframe {
border: 0;
border-radius: 4px;
}
#mainscreen .readtext {
margin: 0 auto;
}
#helptoolbar {
position: absolute;
top: -6px;
left: 0;
height: 40px;
white-space: nowrap;
}
#taskbar a.button-help span.button-inner {
background: url(help.png) 0 0 no-repeat;
height: 19px;
}
#taskbar a.button-help:hover span.button-inner,
#taskbar a.button-help.button-selected span.button-inner {
background: url(help.png) 0 -24px no-repeat;
height: 19px;
}
.toolbar a.button.help {
background: url(help.png) center -51px no-repeat;
}
.toolbar a.button.about {
background: url(help.png) center -89px no-repeat;
}
.toolbar a.button.license {
background: url(help.png) center -130px no-repeat;
}
-.iframebox.help_about,
.iframebox.help_license {
overflow: auto;
}
diff --git a/skins/classic/templates/about.html b/skins/classic/templates/about.html
index 519acf773..429dfcf5f 100644
--- a/skins/classic/templates/about.html
+++ b/skins/classic/templates/about.html
@@ -1,35 +1,42 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><roundcube:object name="pagetitle" /></title>
<roundcube:include file="/includes/links.html" />
<script type="text/javascript" src="/functions.js"></script>
</head>
<body>
+<roundcube:if condition="!request:_framed" />
+
<roundcube:include file="/includes/taskbar.html" />
<roundcube:include file="/includes/header.html" />
<roundcube:include file="/includes/settingstabs.html" />
<div id="mainscreen" class="box darkbg crop">
+<roundcube:endif />
+
<div class="readtext">
<div id="license">
<roundcube:object name="aboutcontent" />
<h2 class="sysname">Roundcube Webmail <roundcube:object name="version" /></h2>
<p class="copyright">Copyright © 2005-2013, The Roundcube Dev Team</p>
<p class="license">This program is free software; you can redistribute it and/or modify
it under the terms of the <a href="http://www.gnu.org/licenses/gpl.html" target="_blank">GNU General Public License</a>
as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.<br/>
Some <a href="http://roundcube.net/license">exceptions</a> for skins & plugins apply.
</p>
<p class="links"><roundcube:object name="supportlink" label="support" target="_blank" /></p>
</div>
<h3><roundcube:label name="installedplugins" /></h3>
<roundcube:object name="pluginlist" id="pluginlist" class="records-table" cellspacing="0" />
</div>
+
+<roundcube:if condition="!request:_framed" />
</div>
+<roundcube:endif />
</body>
</html>
diff --git a/skins/larry/templates/about.html b/skins/larry/templates/about.html
index 301c301a9..e2bd0b019 100644
--- a/skins/larry/templates/about.html
+++ b/skins/larry/templates/about.html
@@ -1,28 +1,32 @@
<roundcube:object name="doctype" value="html5" />
<html>
<head>
<title><roundcube:object name="pagetitle" /></title>
<roundcube:include file="/includes/links.html" />
</head>
+<roundcube:if condition="request:_framed" />
+<body class="iframe fullheight">
+<roundcube:else />
<body class="ui-widget-content">
+<roundcube:endif />
<div class="readtext">
<roundcube:object name="aboutcontent" />
<h2 class="sysname">Roundcube Webmail <roundcube:object name="version" /></h2>
<p class="copyright">Copyright © 2005-2013, The Roundcube Dev Team</p>
<p class="license">This program is free software; you can redistribute it and/or modify
it under the terms of the <a href="http://www.gnu.org/licenses/gpl.html" target="_blank">GNU General Public License</a>
as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.<br/>
Some <a href="http://roundcube.net/license">exceptions</a> for skins & plugins apply.
</p>
</div>
<div class="readtext">
<h3><roundcube:label name="installedplugins" /></h3>
<roundcube:object name="pluginlist" id="pluginlist" class="records-table" />
</div>
</body>
</html>
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Sat, Mar 1, 3:42 AM (1 d, 7 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
165715
Default Alt Text
(11 KB)
Attached To
Mode
R3 roundcubemail
Attached
Detach File
Event Timeline
Log In to Comment