Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Completed Modification: Hiding Menu Buttons Prior to Login  (Read 1864 times)

0 Members and 1 Guest are viewing this topic.

EME

  • Contributor
  • Coppermine newbie
  • ***
  • Offline Offline
  • Posts: 8
Completed Modification: Hiding Menu Buttons Prior to Login
« on: July 24, 2013, 03:55:29 pm »

As mentioned in a previous post, we are using Coppermine as a family history archive.  We decided to make a private site by using the username and password feature.  This way random Internet voyeurs can't wander in and make comments about a letter my great grandmother wrote.

We also decided to hide all of the menu buttons prior to login.  It seemed confusing from a user interface standpoint to have (for instance) an Album List button showing when you couldn't use it on the login screen.

The job was carried out by tying the SYS_MENU and SUB_MENU tokens to the sessions table in MySQL.  Since your user_id = 0 on the table until you log in (at which point it changes to a number greater than 0) it makes for a good dependency.  We made a second version of the token array and enclosed that and the original in an IF...ELSE statement.  While I understand the reasons for putting updates like this in themes, this one was executed on the core (themes.inc.php).  If we change themes in the future we will want the same configuration and this will save work. 

I have attached the rewrtitten section of themes.inc.php as a PDF.  As far as I know this is a clean modification.  But I'd be interested in any comments from the Coppermine development team.

Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Completed Modification: Hiding Menu Buttons Prior to Login
« Reply #1 on: August 23, 2013, 04:13:57 pm »

Thank you for your contribution. Alternatively the Final extract plugin should do the same.
Logged
Pages: [1]   Go Up
 

Page created in 0.019 seconds with 19 queries.