mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-08-08 09:43:01 +02:00
fixes #178, hide menu identification on identification page
+ redirect to gallery root when opening idenfication page while identified
This commit is contained in:
@@ -30,6 +30,13 @@ include_once( PHPWG_ROOT_PATH.'include/common.inc.php' );
|
||||
// +-----------------------------------------------------------------------+
|
||||
check_status(ACCESS_FREE);
|
||||
|
||||
// but if the user is already identified, we redirect to gallery home
|
||||
// instead of displaying the log in form
|
||||
if (!is_a_guest())
|
||||
{
|
||||
redirect(get_gallery_home_url());
|
||||
}
|
||||
|
||||
trigger_notify('loc_begin_identification');
|
||||
|
||||
//-------------------------------------------------------------- identification
|
||||
|
||||
@@ -515,7 +515,13 @@ function register_default_menubar_blocks($menu_ref_arr)
|
||||
$menu->register_block( new RegisteredBlock( 'mbTags', 'Related tags', 'piwigo'));
|
||||
$menu->register_block( new RegisteredBlock( 'mbSpecials', 'Specials', 'piwigo'));
|
||||
$menu->register_block( new RegisteredBlock( 'mbMenu', 'Menu', 'piwigo'));
|
||||
$menu->register_block( new RegisteredBlock( 'mbIdentification', 'Identification', 'piwigo') );
|
||||
|
||||
// We hide the quick identification menu on the identification page. It
|
||||
// would be confusing.
|
||||
if (script_basename() != 'identification')
|
||||
{
|
||||
$menu->register_block( new RegisteredBlock( 'mbIdentification', 'Identification', 'piwigo') );
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user