Changeset 5098 for trunk/admin.php


Ignore:
Timestamp:
Mar 10, 2010, 12:19:11 AM (14 years ago)
Author:
plg
Message:

feature 1491: administration panel header/footer. Graphicaly outside the
administration theme. The header includes the gallery title with a link to
gallery, a theme changer, an explicit "visit gallery" link, a logout link.
The footer includes links to piwigo.org (homepage, documentation, forum) and
the contact webmaster link.

Due to new header/footer, I've removed the "Links" section in the menubar.

The new footer sticks to the bottom of the browser window.

I've slightly "rounded" grum tabs to look like the menubar borders.

Graphical illustration (top left and bottom left leaves) were removed to
improve readability. They make things beautiful on gallery side, they
decrease usability on admin side.

Piwigo logo was removed to save space on administration footer. It would be
nice to have a small logo to place bottom left in the footer next to
"Powered by Piwigo".

Links>Administration link was replaced by a big link box just above the
menubar.

The H2 was outside the #content box, nearly invisible on top right corner.
Now it is 1) easy to read 2) inside #content.

feature 1490: ability to switch from goto/roma to goto/clear with a single
click in administration header.

The global organisation of the page is quite heavily changed. The global
layout is:

body#theAdminPage
body#theAdminPage > #the_page
body#theAdminPage > #the_page > #pwgHead
body#theAdminPage > #the_page > #pwgMain
body#theAdminPage > #the_page > #pwgMain > #menubar
body#theAdminPage > #the_page > #pwgMain > #content
body#theAdminPage > #the_page > #footer

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin.php

    r5089 r5098  
    6060}
    6161
     62// theme changer
     63if (isset($_GET['change_theme']))
     64{
     65  $admin_themes = array('goto/roma', 'goto/clear');
     66
     67  $new_admin_theme = array_pop(
     68    array_diff(
     69      $admin_themes,
     70      array($conf['admin_layout'])
     71      )
     72    );
     73
     74  $query = '
     75DELETE
     76  FROM '.CONFIG_TABLE.'
     77  WHERE param = "admin_layout"
     78;';
     79  pwg_query($query);
     80
     81  $query = '
     82INSERT
     83  INTO '.CONFIG_TABLE.'
     84  SET param = "admin_layout"
     85    , value = "'.$new_admin_theme.'"
     86;';
     87  pwg_query($query);
     88
     89  redirect('admin.php');
     90}
     91
    6292// +-----------------------------------------------------------------------+
    6393// |                    synchronize user informations                      |
     
    95125$template->assign(
    96126  array(
     127    'USERNAME' => $user['username'],
    97128    'U_SITE_MANAGER'=> $link_start.'site_manager',
    98129    'U_HISTORY_STAT'=> $link_start.'stats',
     
    124155    'U_PLUGINS'=> $link_start.'plugins_list',
    125156    'U_ADD_PHOTOS' => $link_start.'photos_add',
     157    'U_CHANGE_THEME' => PHPWG_ROOT_PATH.'admin.php?change_theme=1',
    126158    )
    127159  );
Note: See TracChangeset for help on using the changeset viewer.