Hey,
I'm building a site for a customer that has an external user database he wishes to enable as well on his site.
Basically the setup currently is that a user can either register on his Joomla site with Community Builder or get authenticated via a php curl post.
The site is wanted to function so, that a user don't have to confirm his email after registering, and it works well for users who register via the registration on the site. (Community builder registration).
However, I would also need to get the auto-approve working for user who register via the external database. The code I'm using is somewhat identical to the Joomla's gmail authentication plugin, only difference is that the curl post url is different. Pasting here what the code does in the end once a user has been successfully identified from the external database:
if ($success)
{
$response->status = JAUTHENTICATE_STATUS_SUCCESS;
$response->error_message = '';
$response->email = $aResponse;
$response->fullname = utf8_encode($aResponse . ' ' .$aResponse);
}
else
{
$response->status = JAUTHENTICATE_STATUS_FAILURE;
$response->error_message = 'Failed to authenticate: ' . $message;
}
As far as I know I should add something to the code to make the user auto-approved in community builder, since after a site user has succesfully logged in to Joomla from the external database and attempts to view his profile he gets an error that the account has not yet been approved by a moderator, even though the accounts should be automatically approved.
So, my question is, how to enable the users logging to the site with an external database to become automatically approved? Since I've noticed it requires some hacking to the login / registration.
Thanks!