OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Initial login page takes data, but remains the same

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

Re: Initial login page takes data, but remains the same

Postby asmecher » Thu Jun 21, 2012 11:59 am

Hi Renato,

The login form on the login page has a blank "target" attribute; looking in lib/pkp/templates/user/login.tpl, the form target should come from the $loginUrl variable. That variable is set in PHP in lib/pkp/pages/login/PKPLoginHandler.inc.php around line 59, with a value that comes from pages/login/LoginHandler.inc.php in the _getLoginUrl function. Is there a chance your installation has modifications in any of these files that might affect those parts?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Re: Initial login page takes data, but remains the same

Postby mendesrocha » Thu Jun 21, 2012 12:12 pm

Hi Alec,

Thanks for your attention. You were very precise.

There was a .rej file in lib/pkp/pages/login/ directory. Functions around line 59 had empty arguments, like "function implicitAuthReturn()"

So I updated the file content with github and now page login is working.

Thanks a lot!
mendesrocha
 
Posts: 169
Joined: Mon Nov 05, 2007 11:10 am
Location: Brazil

Re: Initial login page takes data, but remains the same

Postby asmecher » Thu Jun 21, 2012 1:26 pm

Hi Renato,

Great, glad it's working again.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Re: Initial login page takes data, but remains the same

Postby dionphp » Sat Jun 23, 2012 11:29 am

I have a similar problem. I can do a password reset. I do receive a new password from OJS. Then OJS forces you to change the passwrod that was just emailed. I then do so. I can't login immediately, it returns me to the login screen again and again, it does not show a invalid login or invalid password. I have tried with a wrong password and it doies then show the correct error. However, if I leave the browser window with OJS running open after trying to login with the changed password that is after about 5 then I am able toi access all menus as admin without having to login again. This is peculiar, any suggestions will be appreciated.

Here is the URL http://www.uvibusiness.net/ojs
dionphp
 
Posts: 6
Joined: Sun Jun 17, 2012 6:16 am

Re: Initial login page takes data, but remains the same

Postby asmecher » Sun Jun 24, 2012 10:27 am

Hi dionphp,

You've posted essentially the same question on several threads now, and haven't answered the questions I asked here or here. Please don't double-post, and please let me know what you've tried.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Re: Initial login page takes data, but remains the same

Postby dionphp » Sun Jun 24, 2012 1:35 pm

asmecher wrote:Hi dionphp,

You've posted essentially the same question on several threads now, and haven't answered the questions I asked here or here. Please don't double-post, and please let me know what you've tried.

Regards,
Alec Smecher
Public Knowledge Project Team


Alec

I have done the following:

session_check_ip' is disabled
checked cookies on and OJSSID cookie is set

What is strange for me is that when I use password reset, try to login with the new password it does not allow me at first but if I leave it for a while say 5 to 10 minutes and I go back to that window I am logged in as admin and can use the software.

Dion
dionphp
 
Posts: 6
Joined: Sun Jun 17, 2012 6:16 am

Re: Initial login page takes data, but remains the same

Postby asmecher » Sun Jun 24, 2012 4:56 pm

Hi Dion,

From your post at http://pkp.sfu.ca/support/forum/viewtopic.php?f=8&t=920&start=15#p33967 it looks like the "debug" setting is currently turned on. If that's the case, please turn it off again -- it's probably getting in the way of setting cookies.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Unable to login to my journal when not my own computer

Postby Kavitamin » Fri Oct 12, 2012 9:52 am

Dear Alec,

I am unable to log in from other computers to my journal at www.psjt.co.uk. I can log in on my computer and create new users on other computers, but the login page just flashes up with no error message. I am a novice with computers, do you know how i can correct this? Please be basic in your explanataions,

Many thanks,
Kav
Kavitamin
 
Posts: 9
Joined: Fri Oct 12, 2012 9:47 am

Re: Initial login page takes data, but remains the same

Postby asmecher » Fri Oct 12, 2012 11:39 am

Hi Kav,

Have you tried any of the solutions suggested here in the forums or in our FAQ?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Re: Initial login page takes data, but remains the same

Postby Kavitamin » Sat Oct 20, 2012 11:24 am

Hi Alec,

I'm not so familiar with programming spiel, but the section i think you were referring to reads: Apologies for pasting it all out, i just don't know which parts i should be looking at. Any help as always would be much appreciated. There is more text in this file but didn't want to take up the whole blog:

import('classes.handler.Handler');

class PKPLoginHandler extends Handler {

/**
* Display user login form.
* Redirect to user index page if user is already validated.
*/
function index() {
$this->validate();
$this->setupTemplate();
if (Validation::isLoggedIn()) {
PKPRequest::redirect(null, 'user');
}

if (Config::getVar('security', 'force_login_ssl') && Request::getProtocol() != 'https') {
// Force SSL connections for login
PKPRequest::redirectSSL();
}

$sessionManager =& SessionManager::getManager();
$session =& $sessionManager->getUserSession();

$templateMgr =& TemplateManager::getManager();

// If the user wasn't expecting a login page, i.e. if they're new to the
// site and want to submit a paper, it helps to explain why they need to
// register.
if(Request::getUserVar('loginMessage'))
$templateMgr->assign('loginMessage', Request::getUserVar('loginMessage'));

$templateMgr->assign('username', $session->getSessionVar('username'));
$templateMgr->assign('remember', Request::getUserVar('remember'));
$templateMgr->assign('source', Request::getUserVar('source'));
$templateMgr->assign('showRemember', Config::getVar('general', 'session_lifetime') > 0);

// For force_login_ssl with base_url[...]: make sure SSL used for login form
$loginUrl = $this->_getLoginUrl();
if (Config::getVar('security', 'force_login_ssl')) {
$loginUrl = String::regexp_replace('/^http:/', 'https:', $loginUrl);
}
$templateMgr->assign('loginUrl', $loginUrl);

$templateMgr->display('user/login.tpl');
}

/**
* Handle login when implicitAuth is enabled.
* If the user came in on a non-ssl url - then redirect back to the ssl url
*/
function implicitAuthLogin() {
if (Request::getProtocol() != 'https')
PKPRequest::redirectSSL();

$wayf_url = Config::getVar("security", "implicit_auth_wayf_url");

if ($wayf_url == "")
die("Error in implicit authentication. WAYF URL not set in config file.");

$url = $wayf_url . "?target=https://" . Request::getServerHost() . Request::getBasePath() . '/index.php/index/login/implicitAuthReturn';

PKPRequest::redirectUrl($url);
}

/**
* This is the function that Shibboleth redirects to - after the user has authenticated.
*/
function implicitAuthReturn() {
$this->validate();

if (Validation::isLoggedIn()) {
PKPRequest::redirect(null, 'user');
}

// Login - set remember to false
$user = Validation::login(Request::getUserVar('username'), Request::getUserVar('password'), $reason, false);

PKPRequest::redirect(null, 'user');
Kavitamin
 
Posts: 9
Joined: Fri Oct 12, 2012 9:47 am

Re: Initial login page takes data, but remains the same

Postby asmecher » Mon Oct 22, 2012 10:49 am

asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Re: Initial login page takes data, but remains the same

Postby Kavitamin » Tue Oct 23, 2012 12:13 pm

Dear Alec,

This was the first thing we tried. If you register with the journal despite privacy settings, you will be unable to login. I have sent an e-mail to pkp to get into contact with you with more code from various files. Very keen to get this sorted before end of the month. Your help is much appreciated,

Regards,

Kavit
Kavitamin
 
Posts: 9
Joined: Fri Oct 12, 2012 9:47 am

Re: Initial login page takes data, but remains the same

Postby asmecher » Tue Oct 23, 2012 12:24 pm

Hi Kavit,

Have you tried this using another web browser to verify if that makes a difference? Google Chrome or Firefox should be available on pretty much any platform.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

Re: Initial login page takes data, but remains the same

Postby Kavitamin » Wed Oct 24, 2012 12:22 pm

Dear Alec,

I have sent an e-mail to pkp directed to you as well a few days ago to display what code i get. I have checked on firefox and lots of other browsers on other peoples comps including my own machine with privacy settings to a minimum a few weeks back and checked again now with no avail. Still flashes to log in screen other than on my ipad, iphone and mac computer which logs in normally with fake accounts ive set up.

Kav
Kavitamin
 
Posts: 9
Joined: Fri Oct 12, 2012 9:47 am

Re: Initial login page takes data, but remains the same

Postby asmecher » Wed Oct 24, 2012 1:59 pm

Hi Kav,

Is the session_check_ip option turned on in config.inc.php? If so, turn it off.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8478
Joined: Wed Aug 10, 2005 12:56 pm

PreviousNext

Return to OJS Technical Support

Who is online

Users browsing this forum: ctgraham, Google [Bot] and 16 guests