Search the Community
Showing results for tags 'logout'.
-
After doing a Google search for the issue I saw several previous posts mentioning this same issue but cannot figure out how to fix it and shouldn't have to spend a half hour trying to. ProcessWire frequently logs out of the admin area after less than five minutes. It shouldn't time-out ever, and if someone wanted that option for security reasons they should be able to enable it through the settings in their admin panel. In addition to it not being the default setting, users also shouldn't need to edit your config files manually to change these kinds of settings. Please fix the major issue in a future release. It's absured imho that developers don't realize the inconvenience it places on other people if they have to login every time they switch back to that page. It has also logged me out without warning without any visual que that it did so. If someone was working on paragraphs of content they could easily lose their work do to this bug as well... Please don't refer me to a forum with a dozen possible solutions to the issue and fix it yourselves. I'm sick of looking at them. It's your job to troubleshoot your software, not your users!
-
Hey Everyone, Before I get to the issue, thought I'd say hi. I've been using processwire for about a year now for a bunch of small web projects but haven't made a forum account yet. I've really had a great time using it. So far I haven't had any issues that haven't been solved by reading the API or going through the forums. However, it seems that time has finally come. Basically, I keep getting logged out of PW admin. There doesn't seem to be too much of a pattern governing after what amount of time it happens unfortunately. Sometimes 30seconds, sometimes 3 minutes. Today, I was getting logged out everytime I clicked a link on the admin page (any edit, new, save, etc). I saw this forum post: http://processwire.com/talk/topic/2723-strange-loading-and-logout-issues-in-the-admin/?hl=logout and followed what was done there. However, that hasn't really fixed any of my issues. There hasn't been anything in the error log (not that I really expected there to be). For all I know, this could be something on my end. I'm using the newest version of firefox for what it's worth. Any thoughts on the matter would be appreciated, I'll really try anything anyone things might work. Thanks! -Chase
-
If I have two PW sites that sit in separate folders, I can't be logged-in in both sites. e.g. site.com/project-a/pw-admin-slug/ site.com/project-b/pw-admin-slug/ If I login to project-a, then also login to project-b, get back to the first site, I have to login again. Is the cookie / session mechanism storing my domain? If it does, and it's meant to be some sort of security enhancement, it should not check my domain, but root-URL of the PW-installation. (strangely, this doesn't happen on localhost) Is it possible to prevent that behavior? Often I have two sites open (e.g. check to see if I have the same CKEditor setup and quickly copy and paste it, or copy a user-role)
-
Hello, I get often logged out from a web service built with PW. This web service has a large database and I use ListerPro to let my client browse and interact with it. After a couple of manipulations, or around 2-3 minute after logged in, the login page appears again. In this process, the last data submitted in the admin get often lost. About my configuration: The website is hosted on one of the first plans of OVH server (cheap ones), can it may be related to the problem? I uninstalled all the extra modules I used (Redirect, AdminCustomFiles). Nothing changed. The problem appeared recently only (since around 4 days) The website is still using basic http There is nothing interesting neither in `site/assets/logs/errors.txt` nor `site/assets/logs/modules.txt` I sometimes get the red error `This request was aborted because it appears to be forged.` together with `The process returned no content.` after a login attempt. I saw on this forum that it can be related to access rights and checked a couple of files permissions, and I *think* everything is fine. Thanks in advance for your help.
-
I think you can create a simple logout link with <a href="admin/login/logout">log out</a> But it redirects to the login form in the admin area. Can I hook into logout and change the redirect? Default redirect home would make sense. Or is the way to do this still to create a logout template + page with session->logout() and a redirect?
-
Hi all, I'm creating a website for a magazine publisher. This will include a supplier section with press releases attached to company profiles. The idea is that companies can register and manage their profile and press releases (CRUD) via a dashboard. The dashboard is a Process module. Ben Byford's RedirectAdminPages module is being used to lock out the rest of the backend, with a few modifications. The following code should redirect every admin page to the dashboard page but still allowing logging out. However logging out just redirects to the dashboard page: // do not redirect if page matches: if($this->page->template != "admin" // any non-admin page || $this->page->is($this->redirectPage) // the dashboard page (prevent infinite loop) || $this->page->parent->is('/admin/login/') // various attempts to allow logging out || $this->wire("process") == 'ProcessLogin' || strpos($this->page->url, $this->wire('config')->urls->admin . 'login/logout') !== false ) { return; } // find roles set in module configuration and create array $roles = explode(',', $this->userRoles); // for each user in module config check to see if current user foreach ($roles as $key => $val) { // get a role from the roles array $roles[$key] = trim($roles[$key]); // if current user found with role then redirect if($this->user->hasRole($roles[$key])){ // redirect session to page stored in config $this->session->redirect($this->redirectPage); // code should never get here but this is a simple fallback break; } } } } I'm surprised that this URL matching doesn't work: || strpos($this->page->url, $this->wire('config')->urls->admin . 'login/logout') !== false Because this does work for allowing page edit: || strpos($this->page->url, $this->wire('config')->urls->admin . 'page/edit') !== false Any ideas? That issue aside, as a learning process I'm going to re-implement the dashboard as front-end pages. I guess that the advantage of using the ProcessWire back-end is most of the functionality is already there, you don't need to create forms and handle the processing, create / import css etc. So it'll be interesting to see how much of a difference this makes, and how much control each approach provides. I'd love to have some thoughts and feedback from those of you who've tried both methods? PS this will be my third website created with ProcessWire and it's already been a lot of fun, and as a CMS it 'just feels right', so a big thanks to Ryan and everyone who has contributed. Thanks
-
Hello everyone! I have a strange problem in my Processwire 2.7.2 backend. When I try to logout, using the link on the bottom right, I get the following error: «Unrecognized path» and «The process returned no content.» The url in the browser is « http://mysite.ch/processwire/login/logout/ » Everything else works normal. Any ideas? Thanks a lot, tron1000
-
HELLO! I'm using $user->isLoggedin() three times on one template (in the head.inc, template-page.php and foot.inc). I'm using a custom login in my template file: // If they aren't logged in, then show the login form if(!$user->isLoggedin()){ // check for login before outputting markup if($input->post->user && $input->post->pass) { $user = $sanitizer->username($input->post->user); $pass = $input->post->pass; if($session->login($user, $pass)) { // login successful $session->redirect($homepage->url); } else { // login error $session->login_error = 'Login Failed. Please try again, or use the forgot password link below.'; } } if($input->post->user && $input->post->pass) { $login = "<p class='error'>" . $session->login_error . "</p>"; } $login .= "<form action='./' method='post'><div class='login'> <input type='text' id='user' name='user' placeholder='Enter your SP Company Code' /> <input class='hidden' type='password' name='pass' value='' /> <p><input type='submit' class='btn' name='submit' value='Login' /></p> </div></form>"; } // end !logged in Using the correct logins works and everything is cool, but putting the wrong passwords in creates a Internal server error on both the head.inc and foot.inc $user->isLoggedin() functions. I'm probably doing something absurdly stupid here, any ideas? thanks
- 4 replies
-
- internal server
- error
-
(and 3 more)
Tagged with:
-
I use the ProcessWire $session API for a new project to store some things there. Cart items, currency and more. It works fine and the limited lifetime of $sessions is OK, I defined just 3 days. There is only an issue with user $session->logout() to logout an user. It removes all items in user $session too. Website users are just "guest" or after login with role "customer". I see two options to solve my issue: I skip $session API and use instead PHP $_SESSION to keep all vars after $session->logout(). This make things more complicated and I would prefer to use PW API only. Anyone way to avoid the $session->logout() command. So that logout means remove the role "customer" temporary from user session, be only guest. Without $session->logout(). Mhhmmmm. Maybe I think wrong, ideas are welcome. BTW, I enjoy it to work with PW.