mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-08-07 17:23:04 +02:00
feature 1519: admin instructions are dispatched into several tabs. Only
applied to en_UK and fr_FR. The help content itself needs some updates but it will be another set of commits, in this commit, I nearly only modified the container. The new "Add Photos" help page only introduces you to 3 main ways to add photos: direct upload, pLoader and FTP. Each of them has a dedicated tab on the Admin>Photos>Add screen. No use of the big question mark icon linked to the Help pages in the administration header, to avoid having this icon twice : in the header + in the content next to H2. git-svn-id: http://piwigo.org/svn/trunk@5182 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
+73
-1
@@ -22,11 +22,83 @@
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
|
||||
include_once(PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php');
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | Check Access and exit when user status is not ok |
|
||||
// +-----------------------------------------------------------------------+
|
||||
check_status(ACCESS_ADMINISTRATOR);
|
||||
|
||||
$template->assign('ADMIN_CONTENT', load_language('help.html','',array('return'=>true)) );
|
||||
$link = get_root_url().'admin.php?page=help§ion=';
|
||||
$selected = null;
|
||||
$help_section_title = null;
|
||||
|
||||
$tabs = array(
|
||||
array(
|
||||
'code' => 'add_photos',
|
||||
'label' => 'Add Photos',
|
||||
),
|
||||
array(
|
||||
'code' => 'permissions',
|
||||
'label' => 'Permissions',
|
||||
),
|
||||
array(
|
||||
'code' => 'groups',
|
||||
'label' => 'Groups',
|
||||
),
|
||||
array(
|
||||
'code' => 'user_upload',
|
||||
'label' => 'User Upload',
|
||||
),
|
||||
array(
|
||||
'code' => 'virtual_links',
|
||||
'label' => 'Virtual Links',
|
||||
),
|
||||
array(
|
||||
'code' => 'misc',
|
||||
'label' => 'Miscellaneous',
|
||||
),
|
||||
);
|
||||
|
||||
if (!isset($_GET['section']))
|
||||
{
|
||||
$section = $tabs[0]['code'];
|
||||
}
|
||||
else
|
||||
{
|
||||
$section = $_GET['section'];
|
||||
}
|
||||
|
||||
$tabsheet = new tabsheet();
|
||||
foreach ($tabs as $tab)
|
||||
{
|
||||
if ($tab['code'] == $section)
|
||||
{
|
||||
$selected_tab = $tab['code'];
|
||||
$help_section_title = l10n($tab['label']);
|
||||
}
|
||||
|
||||
$tabsheet->add($tab['code'], l10n($tab['label']), $link.$tab['code']);
|
||||
}
|
||||
$tabsheet->select($selected_tab);
|
||||
$tabsheet->assign();
|
||||
|
||||
$template->set_filenames(array('help' => 'help.tpl'));
|
||||
|
||||
$template->assign(
|
||||
array(
|
||||
'HELP_CONTENT' => load_language(
|
||||
'help/help_'.$selected_tab.'.html',
|
||||
'',
|
||||
array('return'=>true)
|
||||
),
|
||||
'HELP_SECTION_TITLE' => $help_section_title,
|
||||
)
|
||||
);
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | sending html code |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
$template->assign_var_from_handle('ADMIN_CONTENT', 'help');
|
||||
?>
|
||||
|
||||
@@ -147,7 +147,15 @@ $tabs = array(
|
||||
array(
|
||||
'code' => 'settings',
|
||||
'label' => 'Settings',
|
||||
)
|
||||
),
|
||||
array(
|
||||
'code' => 'ploader',
|
||||
'label' => 'Piwigo Uploader',
|
||||
),
|
||||
array(
|
||||
'code' => 'ftp',
|
||||
'label' => 'FTP + Synchronisation',
|
||||
),
|
||||
);
|
||||
|
||||
$tab_codes = array_map(
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | Piwigo - a PHP based picture gallery |
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | Copyright(C) 2010 Pierrick LE GALL http://piwigo.org |
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | This program is free software; you can redistribute it and/or modify |
|
||||
// | it under the terms of the GNU General Public License as published by |
|
||||
// | the Free Software Foundation |
|
||||
// | |
|
||||
// | This program is distributed in the hope that it will be useful, but |
|
||||
// | WITHOUT ANY WARRANTY; without even the implied warranty of |
|
||||
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
||||
// | General Public License for more details. |
|
||||
// | |
|
||||
// | You should have received a copy of the GNU General Public License |
|
||||
// | along with this program; if not, write to the Free Software |
|
||||
// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, |
|
||||
// | USA. |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
if (!defined('PHOTOS_ADD_BASE_URL'))
|
||||
{
|
||||
die ("Hacking attempt!");
|
||||
}
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | template init |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
$template->assign(
|
||||
'FTP_HELP_CONTENT',
|
||||
load_language(
|
||||
'help/photos_add_ftp.html',
|
||||
'',
|
||||
array('return'=>true)
|
||||
)
|
||||
);
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | sending html code |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
$template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');
|
||||
?>
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | Piwigo - a PHP based picture gallery |
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | Copyright(C) 2010 Pierrick LE GALL http://piwigo.org |
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | This program is free software; you can redistribute it and/or modify |
|
||||
// | it under the terms of the GNU General Public License as published by |
|
||||
// | the Free Software Foundation |
|
||||
// | |
|
||||
// | This program is distributed in the hope that it will be useful, but |
|
||||
// | WITHOUT ANY WARRANTY; without even the implied warranty of |
|
||||
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
||||
// | General Public License for more details. |
|
||||
// | |
|
||||
// | You should have received a copy of the GNU General Public License |
|
||||
// | along with this program; if not, write to the Free Software |
|
||||
// | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, |
|
||||
// | USA. |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
if (!defined('PHOTOS_ADD_BASE_URL'))
|
||||
{
|
||||
die ("Hacking attempt!");
|
||||
}
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | template init |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
$template->assign(
|
||||
array(
|
||||
'URL_DOWNLOAD_WINDOWS' => $conf['ploader_download_windows'],
|
||||
'URL_DOWNLOAD_MAC' => $conf['ploader_download_mac'],
|
||||
'URL_DOWNLOAD_LINUX' => $conf['ploader_download_linux'],
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
// | sending html code |
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
||||
$template->assign_var_from_handle('ADMIN_CONTENT', 'plugin_admin_content');
|
||||
?>
|
||||
@@ -209,4 +209,7 @@ html>body #menubar {min-height:477px; height:477px;} /* IE 7 and modern browsers
|
||||
#themesContent H3 {border-bottom:1px solid #aaa;}
|
||||
.themeDefault {background-color:#dbe8f3;}
|
||||
|
||||
#pluginsMenuSeparator {border:1px solid #ddd;}
|
||||
#pluginsMenuSeparator {border:1px solid #ddd;}
|
||||
|
||||
#helpContent A {border-bottom:1px dotted #005E89;}
|
||||
#helpContent A:hover {border-bottom:1px solid #d54e21;}
|
||||
@@ -540,7 +540,7 @@ ul.holder li.bit-box-focus a.closebutton, ul.holder li.bit-box-focus a.closebutt
|
||||
}
|
||||
|
||||
#pwgHead {
|
||||
background-color:#222;
|
||||
background-color:#464646;
|
||||
height:46px;
|
||||
}
|
||||
|
||||
@@ -744,4 +744,8 @@ BODY#thePopuphelpPage {
|
||||
h2 { letter-spacing:2px; font-weight:bold;}
|
||||
h2:lang(en) { text-transform:capitalize; }
|
||||
|
||||
#pluginsMenuSeparator {width:80%; margin:5px auto;}
|
||||
#pluginsMenuSeparator {width:80%; margin:5px auto;}
|
||||
|
||||
#helpContent P {text-align:left; margin-left:10px;}
|
||||
#helpContent LI, #ftpPage LI {margin-top:10px;}
|
||||
#helpContent P.nextStepLink {text-align:center; font-weight:bold; margin-bottom:20px;}
|
||||
@@ -48,9 +48,9 @@
|
||||
<div id="headActions">
|
||||
Hello {$USERNAME} :
|
||||
<a href="{$U_RETURN}" title="Visit Gallery">Visit Gallery</a> |
|
||||
<a href="{$U_CHANGE_THEME}" title="Switch to clear theme for administration">Change Theme</a> |
|
||||
<a href="{$U_CHANGE_THEME}" title="Switch to clear theme for administration">Change Admin Colors</a> |
|
||||
<a href="{$U_FAQ}" title="{'Instructions to use Piwigo'|@translate}">Help Me</a> |
|
||||
<a href="{$U_LOGOUT}">{'Logout'|@translate}</a>
|
||||
<a href="{$U_FAQ}" title="{'Instructions'|@translate}" id="instructions"><img style="padding-left:10px;" src="{$ROOT_URL}admin/themes/default/icon/help.png" class="button" alt="(?)"></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
<h2>{'Help'|@translate} » {$HELP_SECTION_TITLE}</h2>
|
||||
|
||||
<div id="helpContent">
|
||||
|
||||
{$HELP_CONTENT}
|
||||
|
||||
</div>
|
||||
@@ -0,0 +1,7 @@
|
||||
<div class="titrePage" style="height:25px">
|
||||
<h2>{'FTP + Synchronization'|@translate}</h2>
|
||||
</div>
|
||||
|
||||
<div id="ftpPage">
|
||||
{$FTP_HELP_CONTENT}
|
||||
</div>
|
||||
@@ -0,0 +1,88 @@
|
||||
{literal}
|
||||
<script type="text/javascript">
|
||||
$().ready(function(){
|
||||
$("#pLoaderPage img").fadeTo("fast", 0.6);
|
||||
|
||||
$("#pLoaderPage img").hover(
|
||||
function(){
|
||||
$(this).fadeTo("fast", 1.0); // Opacity on hover
|
||||
},
|
||||
function(){
|
||||
$(this).fadeTo("fast", 0.6); // Opacity on mouseout
|
||||
}
|
||||
);
|
||||
});
|
||||
</script>
|
||||
|
||||
<style>
|
||||
#pLoaderPage {
|
||||
width:600px;
|
||||
margin:0 auto;
|
||||
font-size:1.1em;
|
||||
}
|
||||
|
||||
#pLoaderPage P {
|
||||
text-align:left;
|
||||
}
|
||||
|
||||
#pLoaderPage .downloads {
|
||||
margin:10px auto 0 auto;
|
||||
}
|
||||
|
||||
#pLoaderPage .downloads A {
|
||||
display:block;
|
||||
width:150px;
|
||||
text-align:center;
|
||||
font-size:16px;
|
||||
font-weight:bold;
|
||||
}
|
||||
|
||||
#pLoaderPage .downloads A:hover {
|
||||
border:none;
|
||||
}
|
||||
|
||||
#pLoaderPage LI {
|
||||
margin:20px;
|
||||
}
|
||||
</style>
|
||||
{/literal}
|
||||
|
||||
<div class="titrePage">
|
||||
<h2>{'Piwigo Uploader'|@translate}</h2>
|
||||
</div>
|
||||
|
||||
<div id="pLoaderPage">
|
||||
<p>pLoader stands for <em>Piwigo Uploader</em>. From your computer, pLoader prepares your photos and transfer them to your Piwigo photo gallery.</p>
|
||||
|
||||
<ol>
|
||||
<li>
|
||||
Download,
|
||||
|
||||
<table class="downloads">
|
||||
<tr>
|
||||
<td>
|
||||
<a href="{$URL_DOWNLOAD_WINDOWS}">
|
||||
<img src="http://piwigo.org/screenshots/windows.png"/>
|
||||
<br>Windows
|
||||
</a>
|
||||
<td>
|
||||
<td>
|
||||
<a href="{$URL_DOWNLOAD_MAC}">
|
||||
<img src="http://piwigo.org/screenshots/mac.png" />
|
||||
<br>Mac
|
||||
</a>
|
||||
<td>
|
||||
<td>
|
||||
<a href="{$URL_DOWNLOAD_LINUX}">
|
||||
<img src="http://piwigo.org/screenshots/linux.png" />
|
||||
<br>Linux
|
||||
</a>
|
||||
<td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</li>
|
||||
<li>Install on your computer,</li>
|
||||
<li>Start pLoader and add your photos.</li>
|
||||
</ol>
|
||||
</div>
|
||||
@@ -221,4 +221,6 @@ html>body #menubar {min-height:522px; height:522px;} /* IE 7 and modern browsers
|
||||
.themeActions A {border-bottom:none;}
|
||||
.themeDefault {background-color:#555;}
|
||||
|
||||
#pluginsMenuSeparator {border:1px solid #333;}
|
||||
#pluginsMenuSeparator {border:1px solid #333;}
|
||||
|
||||
#helpContent, #pLoaderPage, #ftpPage, #ftpPage LEGEND {color:#aaa;}
|
||||
Reference in New Issue
Block a user