I am using PHPMaker 2024 and my first time to create goole login
Now successfully intigrated google login. When I open my website It has a option for Google login. and after clicking to it, it redirect to https://mydomain/index and got an error as
401
Unauthorized
You do not have permission to access /index.
How to map this google user login with my PHPMaker user table.
And when a new user is login from google how can I record the data to my user table
inside User_CustomValidate(&$usr, &$pwd)
the IsAuthenticated() always return false. But in the help file of PHPMaker it is written as -
external provider (Google, Facebook, Microsoft, or SAML), the user is pre-authenticated when this server event is fired. You can use IsAuthenticated() to verify.
How can I get all the data pass from google. e.g. firstname, lastname etc.
When a new user is login using google, how can i add the userdata to the user table
Got an error as-
/home/xxx/public_html/subdomain/mobile/src/AdvancedSecurity.php(1423): Call to undefined function PHPMaker2024\Mobile\TwoFactorAuthenticationType()
Here in my case I can get the google user data
Now If the new user login I want to insert the data to the UserTable and allow the user to login and process asking them to enter the mobile no. and password etc.
There is no need to get the user profile yourself, you should be able to get them from the properties of CurrentUser(), you may var_dump() it to check first.
public function userCustomValidate(&$usr, &$pwd)
{
var_dump(CurrentUser());
exit();
return false;
}
I got NULL value after login from google
Now If the new user login I want to insert the data to the UserTable and allow the user to login and process asking them to enter the mobile no. and password etc.
Here I am confuse what I have to do -
After google successful login, if the user is new or not found in the database then I want to collect mobile no. and password and continue the login process. So that the user does not disturb in the login process