當前位置: 首頁>>代碼示例>>PHP>>正文


PHP sendUserVerificationMail函數代碼示例

本文整理匯總了PHP中sendUserVerificationMail函數的典型用法代碼示例。如果您正苦於以下問題:PHP sendUserVerificationMail函數的具體用法?PHP sendUserVerificationMail怎麽用?PHP sendUserVerificationMail使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了sendUserVerificationMail函數的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: resendEmailVerify

function resendEmailVerify()
{
    $app = \Slim\Slim::getInstance();
    $app->response->headers->set('Content-Type', 'application/json');
    $app->response->setStatus(200);
    $user_id = $app->request()->params("user_id");
    $email_id = $app->request()->params("email");
    $lang_id = (int) $app->request()->params("lang_id");
    $currentLanguageId = getCurrentLanguages($lang_id);
    $user = BOL_UserService::getInstance()->findUserById($user_id);
    $email = htmlspecialchars(trim($email_id));
    if ($user->email != $email) {
        BOL_UserService::getInstance()->updateEmail($user->id, $email);
        $user->email = $email;
    }
    sendUserVerificationMail($user);
    if ($currentLanguageId == '32') {
        $messages = "Bestätigungsemail wurde versandt";
    } else {
        if ($currentLanguageId == '33') {
            $messages = "La verificación de email ha sido enviada con éxito";
        } else {
            $messages = "Verification email successfully sent";
        }
    }
    $return_data = array("response_status" => '1', "response_message" => $messages);
    $app->response->setBody(json_encode($return_data));
}
開發者ID:hardikamutech,項目名稱:hammu,代碼行數:28,代碼來源:index_23-6-2015.php

示例2: resendEmailVerify

function resendEmailVerify()
{
    $app = \Slim\Slim::getInstance();
    $app->response->headers->set('Content-Type', 'application/json');
    $app->response->setStatus(200);
    //Lang Call Start
    $hammu_lang_id = $app->request()->params("lang_id");
    if (!empty($hammu_lang_id)) {
        getCurrentLanguages($hammu_lang_id);
    }
    //Lang Call end
    $user_id = $app->request()->params("user_id");
    $email_id = $app->request()->params("email");
    $user = BOL_UserService::getInstance()->findUserById($user_id);
    $email = htmlspecialchars(trim($email_id));
    if ($user->email != $email) {
        BOL_UserService::getInstance()->updateEmail($user->id, $email);
        $user->email = $email;
    }
    sendUserVerificationMail($user);
    $messages = $language->text("hammu", "resend_mail_sent_success");
    //"Verification email successfully sent";
    $return_data = array("response_status" => '1', "response_message" => $messages);
    $app->response->setBody(json_encode($return_data));
}
開發者ID:bhushansonar,項目名稱:hammu,代碼行數:25,代碼來源:index_4_7_2015.php

示例3: signup

function signup()
{
    global $Userservice;
    global $SKADATE_BOL_AccountTypeToGenderDao;
    global $BOL_AvatarService_inst;
    global $EmailVerifyService;
    $app = \Slim\Slim::getInstance();
    $app->response->headers->set('Content-Type', 'application/json');
    $app->response->setStatus(200);
    //$match_sex = $app->request()->params('match_sex');
    //$preferences_or_services = $app->request()->params('preferences_or_services');
    //$photo = $app->request()->params('photo');
    //$photo_data = $_FILES["photo"];
    $username = $app->request()->params('username');
    $email = $app->request()->params('email');
    $password = $app->request()->params('password');
    $realname = $app->request()->params('realname');
    $sex = $app->request()->params('sex');
    $i_m_using = $app->request()->params(HAMMU_DB_IM_USING_HAMMU_AS_KEY);
    $googlemap_location = $app->request()->params('googlemap_location');
    $birthdate = $app->request()->params('birthdate');
    $mobile_number = $app->request()->params(HAMMU_DB_MOBILE_NUMBER_KEY);
    $meeting_point = $app->request()->params(HAMMU_DB_METTING_POINT_KEY);
    $pay_pal_address = $app->request()->params(HAMMU_DB_PAYMENT_TYPE_KEY);
    $token = $app->request()->params('token');
    $type = $app->request()->params('type');
    $preferences = $app->request()->params(HAMMU_DB_SERVICES_KEY);
    $deviceId = $token;
    $deviceType = $type;
    $preferenceArr = explode(",", $preferences);
    $preVal = 0;
    foreach ($preferenceArr as $key => $value) {
        $preVal = $preVal + $value;
    }
    $data["email"] = urldecode($email);
    $data["username"] = $username;
    $data['password'] = $password;
    $data["googlemap_location"] = $googlemap_location;
    $data["birthdate"] = $birthdate;
    $data[HAMMU_DB_MOBILE_NUMBER_KEY] = $mobile_number;
    $data["sex"] = $sex;
    $today_date_timestamp = strtotime(date("d-m-Y"));
    $birth_date_timestamp = strtotime($birthdate);
    if ($birth_date_timestamp > $today_date_timestamp) {
        $return_data = array("response_status" => "0", "response_message" => "Please Provide Proper Date!");
        $app->response->setBody(json_encode($return_data));
    } else {
        $crdata = checkuserexists($data);
        if (count($crdata) > 0) {
            $app->response->setBody(json_encode($crdata));
        } else {
            $username = trim(preg_replace('/[^\\w]/', '', $username));
            $username = makeUsername($username);
            $data['realname'] = $username;
            $newUser = false;
            $accountdata = $SKADATE_BOL_AccountTypeToGenderDao->findByGenderValue($sex);
            $accounttype = $accountdata[0]->accountType;
            $user = $Userservice->createUser($username, $password, $data["email"], $accounttype, false);
            sendUserVerificationMail($user);
            $newUser = true;
            unset($data['email']);
            unset($data['password']);
            unset($data['username']);
            //Geo location settings on address
            $price = $app->request()->params(HAMMU_DB_PRICE_KEY);
            if (!empty($price)) {
                $final_price = $price;
            } else {
                $final_price = "";
            }
            if (!empty($data["googlemap_location"])) {
                $urlencode_address = urlencode($data["googlemap_location"]);
                $geocode = file_get_contents('http://maps.google.com/maps/api/geocode/json?address=' . $urlencode_address . '&sensor=false');
                $output = json_decode($geocode);
                if (!empty($output->results[0]->formatted_address)) {
                    $data_location[HAMMU_DB_PRICE_KEY] = $final_price;
                    $data_location['googlemap_location']['address'] = $output->results[0]->formatted_address;
                    $data_location['googlemap_location']['latitude'] = $output->results[0]->geometry->location->lat;
                    $data_location['googlemap_location']['longitude'] = $output->results[0]->geometry->location->lng;
                    $data_location['googlemap_location']['northEastLat'] = $output->results[0]->geometry->bounds->northeast->lat;
                    $data_location['googlemap_location']['northEastLng'] = $output->results[0]->geometry->bounds->northeast->lng;
                    $data_location['googlemap_location']['southWestLat'] = $output->results[0]->geometry->bounds->southwest->lat;
                    $data_location['googlemap_location']['southWestLng'] = $output->results[0]->geometry->bounds->southwest->lng;
                    $data_location['googlemap_location']['json'] = json_encode($output->results[0]);
                    $data_location['birthdate'] = $data["birthdate"];
                    $data_location['sex'] = $sex;
                    $data_location['realname'] = $realname;
                    $data_location[HAMMU_DB_MOBILE_NUMBER_KEY] = $data[HAMMU_DB_MOBILE_NUMBER_KEY];
                    $data_location[HAMMU_DB_SERVICES_KEY] = $preVal;
                    $data_location[HAMMU_DB_PAYMENT_TYPE_KEY] = $pay_pal_address;
                    $data_location[HAMMU_DB_IM_USING_HAMMU_AS_KEY] = $i_m_using;
                    $data_location[HAMMU_DB_METTING_POINT_KEY] = $meeting_point;
                }
            }
            if ($i_m_using == "1") {
                array_shift($data_location);
            }
            //            print_r($data_location);
            //            exit;
            BOL_QuestionService::getInstance()->saveQuestionsData(array_filter($data_location), $user->id);
//.........這裏部分代碼省略.........
開發者ID:hardikamutech,項目名稱:hammu,代碼行數:101,代碼來源:index_3_6_2015.php


注:本文中的sendUserVerificationMail函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。