가 CB 자동 로그인을위한 솔루션이며, 이메일 확인이 필요하지 않을 경우 등록 후 리디렉션 :
편집 :
echo "\n<div>" . implode("</div>\n<div>", $messagesToUser) . "</div>\n";
: 1078 주위에 라인이 있습니다
/components/com_comprofiler/comprofiler.php을 이것을 (로그인에서 빼냄) :
//lets try to auto-login
$app = &JFactory::getApplication();
$password = cbGetParam($_POST, 'password', '', _CB_ALLOWRAW);
if($app->isSite())
{
# Login process
$credentials = array(
"username" => $username,
"password" => $password
);
if(is_dir(JPATH_BASE . DS . "components" . DS . "com_comprofiler")) {
$database = &JFactory::getDBO();
$sql_sync = "INSERT IGNORE INTO #__comprofiler(id, user_id) SELECT id,id FROM #__users";
$database->setQuery($sql_sync);
$database->query();
}
$app->login($credentials);
// Beside a redirection, writing out a text...
global $mainframe;
$mainframe->redirect(JRoute::_("<redirect-to-link>"),JText::_("You have logged in automatically."));
}
else {
// This is just a redirection...
global $mainframe;
$mainframe->redirect(JRoute::_("<redirect-to-link>"));
}
와우! 내 문제를 해결했다. 고맙습니다. :) –