The following warnings occurred:
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.2.25 (Linux)
File Line Function
/global.php(961) : eval()'d code 26 errorHandler->error
/global.php 961 eval
/showthread.php 28 require_once





× This forum is read only. As of July 23, 2019, the UserSpice forums have been closed. To receive support, please join our Discord by clicking here. Thank you!

  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to set the page shown after the user login
#1
Question 
Hi,

now the user is redirected to users/account.php after the successful login
How to change it?
For example, I would like to keep the user on the home page?

Eugene
  Reply
#2
(01-18-2019, 10:38 AM)Aido Wrote: Hi,

now the user is redirected to users/account.php after the successful login
How to change it?
For example, I would like to keep the user on the home page?

Eugene

Hi Aido,
It is set in the dashboard on the settings page.  It's called Redirect after login I believe.
You will see that it currently says users/account.php in the box.
  Reply
#3
(01-18-2019, 10:39 AM)mudmin Wrote:
(01-18-2019, 10:38 AM)Aido Wrote: Hi,

now the user is redirected to users/account.php after the successful login
How to change it?
For example, I would like to keep the user on the home page?

Eugene

Hi Aido,
It is set in the dashboard on the settings page.  It's called Redirect after login I believe.
You will see that it currently says users/account.php in the box.

Sorry, I could not find it...

Dear UserSpice users

could you help me to find this setting? :-)


Attached Files Thumbnail(s)
   
  Reply
#4
I'm sorry. It's in 4.4 but idk what happened to the setting in 4.3.
The easiest thing to do is to add a line to usersc/scripts/custom_login_script.php and just put Redirect::to('index.php');

Note that you can do conditional logic like

if(hasPerm([2],$user->data()->id)){ //admin
Redirect::to('admin.php);
}else{
Redirect::to('index.php');
}
  Reply
#5
Thank you!
  Reply
#6
Happy to help. Just know that when you update to 4.4 that setting will override what you put in the dashboard.
  Reply


Forum Jump:


Users browsing this thread: 5 Guest(s)