$jUserEmailId = $userMapModel->getJoomlaUserIdFromEmail($providerEmail);
if (!empty($jUserEmailId))
{
// Found a user with the same email address
// do final check to make sure there isn't a FB account already mapped to it
$tempId = $userMapModel->getProviderUserId($jUserEmailId, strtolower($provider->name));
if (!$tempId)
{
SCSocialUtilities::clearJFBCNewMappingEnabled();
if ($userMapModel->map($jUserEmailId, $providerUserId, strtolower($provider->name), $provider->client->getToken()))
{
$app->enqueueMessage(JText::sprintf('COM_JFBCONNECT_MAP_USER_SUCCESS', $provider->name));
$jUserId = $jUserEmailId; // Update the temp jId so that we login below
}
else
$app->enqueueMessage(JText::sprintf('COM_JFBCONNECT_MAP_USER_FAIL', $provider->name));
}
}else
{
$app->enqueueMessage("Oh no! You don't have an account here yet. Please contact some cool guy to get one first");
$app->redirect('index.php');
}else
$itemid = JRequest::getVar('Itemid');
$application = JFactory::getApplication();
$menu = $application->getMenu();
$item = $menu->getItem($itemid);
$link = new JURI($item->link);
$link->setVar('ItemId', $itemid);
if ( $itemid == '487' ) {
{
$app->enqueueMessage("Oh no! You don't have an account here yet. Please contact some cool guy to get one first");
$app->redirect('index.php');
}
}Not sure what you mean by this. Right now, JFBConnect can pull in various Twitter info and it should work. The only thing we can't get is email address because that's not something that Twitter allows access too.Will definitely be resubscribing for the new release that hopefully pulls in twitter info on account creation too!
Gotcha. I was confused because that's not a Twitter specific issue.. the data isn't populated for any extension.. but if you have Auto Registration enabled, then Twitter would be the only one you'd likely notice the problem on. This is in our tracker to-do list, but isn't planned until the 6.3 release, late this year.I was talking about bringing twitter information into the initial registration for K2 as we had been talking about in another thread a few days ago...
We don't perform paid customization services. We do, however, support all our users however we can. I'd have to investigate this a bit further to determine the best way to do it. We do save the page the user came from in a session variable, but I'm not sure if it'd always be accurate enough for the purposes you need. I think it would work though. If you want to tinker, you can try the following code:Would you be able to do this, and at what cost... I can grant you access to my installation/ftp etc.
$redirect = JFactory::getApplication()->getUserState('com_jfbconnect.login.return', 'index.php');I'm not sure what you mean by this at all.Would you also be able to help forcing the Itemid after specific redirects?
was that, when automatically registering an account, and sending a user-activation email, the user is redirected to the sign in page, but with the wrong itemID, so where can I add that in?Would you also be able to help forcing the Itemid after specific redirects?
That URL isn't the page that you clicked the Facebook button from? That's strange. When you're testing, you can't just refresh the page, you'll need to actually test the full login/registration process. If the URL always looks like the one above, try from a few different pages to see if it ever changes, as that will help narrow down if my thinking is wrong about that value.$redirect returns "index.php?option=com_users&view=profile" but it doesn't include any information about the ItemID..
Ahh.. the redirect after a failed login is generated by Joomla itself *if* you've set the "new user redirection" link to a registered page. Basically, JFBC is redirecting to the page you set, but Joomla is denying them access and bringing them to the login page.was that, when automatically registering an account, and sending a user-activation email, the user is redirected to the sign in page, but with the wrong itemID, so where can I add that in?
It'd be a nice feature if you could always force the itemID on any registration/password/login page from the back end so that you don't have to modify core code...
Join our newsletter to get alerts for Joomla releases, tips and tricks and extension updates.
