Hello all.
I want to link to pw admin from a web page on my site, in wich a user is already logged in.
How can I pass the credentials to avoid pw firing the login page?
Thanks,
4 replies to this topic
#2
Posted 13 May 2012 - 10:32 AM
Is the web site also running in PW? If so, then PW won't show the login page. But your question makes me think the user is logged into some software other than ProcessWire. The question is, which software are we talking about? That may help us to determine how best to authenticate them with PW too.
#3
Posted 14 May 2012 - 01:34 PM
Hello, I'm eisenberg partner.
Thanks for your quick answer.
We are integrating PW into OpenCart an would like to run it from a menu option in OC admin.
What I'm thinking is to supply PW a user/password from the OC application.
Let me congratulate you for what I think is the best CMS for developers.
Thanks for your quick answer.
We are integrating PW into OpenCart an would like to run it from a menu option in OC admin.
What I'm thinking is to supply PW a user/password from the OC application.
Let me congratulate you for what I think is the best CMS for developers.
#4
Posted 16 May 2012 - 11:39 AM
That's a tough question to answer, because usually we're trying to prevent this sort of thing from a security standpoint. So I think that the solution will involve creating your own template to perform the login. Something like this:
Then have your OpenCart page POST the 'user' and 'pass' to the page using that template, when they click a "go to ProcessWire" button, or something like that.
<?php
if($input->post->user && $input->post->pass) {
$username = $sanitizer->username($input->post->user);
if($session->login($username, $input->post->pass)) {
$session->redirect('/path/to/page/');
} else echo "Login failed";
}
Then have your OpenCart page POST the 'user' and 'pass' to the page using that template, when they click a "go to ProcessWire" button, or something like that.
Also tagged with one or more of these keywords: login
Community Support →
Getting Started →
Register users and add page same as usernameStarted by vineonardo, 14 May 2013 |
|
|
||
Community Support →
General Support →
When logging in to Admin getting unable to generate password hashStarted by alanfluff, 10 May 2013 |
|
|
||
Community Support →
General Support →
System error on login failureStarted by onjegolders, 03 May 2013 |
|
|
||
Community Support →
General Support →
Calling logout from within a wordpress installStarted by AnotherAndrew, 24 Apr 2013 |
|
|
||
Community Support →
General Support →
Multisite install login problem?Started by photoman355, 09 Apr 2013 |
|
|
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users












