mirror of
https://github.com/ZoneMinder/zoneminder.git
synced 2026-05-18 11:35:15 -04:00
Add a redirect after user delete so that we don't have form resubmission
This commit is contained in:
@@ -43,12 +43,15 @@ if ( $action == 'delete' ) {
|
||||
} # end if isset($_REQUEST['object'] )
|
||||
} else if ( isset($_REQUEST['markUids']) ) {
|
||||
// deletes users
|
||||
foreach( $_REQUEST['markUids'] as $markUid )
|
||||
foreach ($_REQUEST['markUids'] as $markUid)
|
||||
dbQuery('DELETE FROM Users WHERE Id = ?', array($markUid));
|
||||
if ( $markUid == $user->Id() )
|
||||
if ($markUid == $user->Id()) {
|
||||
userLogout();
|
||||
$redirect = '?view=login';
|
||||
} else {
|
||||
$redirect = '?view=options&tab=users';
|
||||
}
|
||||
}
|
||||
|
||||
} else if ( $action == 'options' && isset($_REQUEST['tab']) ) {
|
||||
|
||||
$result = dbQuery('SELECT Name,Value,Type,`System` FROM Config WHERE Category=? ORDER BY Id ASC', array($_REQUEST['tab']));
|
||||
|
||||
Reference in New Issue
Block a user