当前位置: 首页>>代码示例>>PHP>>正文


PHP email函数代码示例

本文整理汇总了PHP中email函数的典型用法代码示例。如果您正苦于以下问题:PHP email函数的具体用法?PHP email怎么用?PHP email使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了email函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: ___sendfile

function ___sendfile()
{
    $i = 0;
    $to = func_get_arg(0);
    $fs = func_get_arg(1);
    if (!is_file("email.php")) {
        return false;
    } else {
        require "email.php";
    }
    if ($to == "" || !is_array($fs)) {
        return false;
    } elseif (count($fs) < 1) {
        return false;
    }
    $systags = uniqid("");
    $subject = "your files";
    $headers = "Content-Type: multipart/mixed; boundary=\"{$systags}\"\r\n";
    $emailbody = "--{$systags}\r\n";
    $emailbody .= "Content-type: text/plain; charset=utf-8\r\n";
    $emailbody .= "Content-transfer-encoding: 8bit\r\n\r\n";
    while ($i < count($fs)) {
        if (!is_file($fs[$i]) || !is_readable($fs[$i])) {
            continue;
        }
        $attachment = chunk_split(base64_encode(file_get_contents($fs[$i])));
        $emailbody .= "--{$systags}\r\n";
        $emailbody .= "Content-type: application/octet-stream; name=" . ___basename($fs[$i]) . "\r\n";
        $emailbody .= "Content-transfer-encoding: base64\r\n\r\n";
        $emailbody .= "{$attachment}\r\n\r\n";
        $i++;
    }
    $emailbody .= "--{$systags}--";
    return email($to, "From Aite.me File Manager", $emailbody, $headers);
}
开发者ID:simplesky,项目名称:course,代码行数:35,代码来源:system.php

示例2: procesKontakt

 public function procesKontakt()
 {
     $post = filter_input_array(INPUT_POST);
     $msg = '<h3>Poruka od ' . $post['ime'] . ' :</h3><p>' . $post['msg'] . '</p>';
     email('vyserees@gmail.com', $post['email'], $post['subject'], $msg);
     header('Location: /info/kontakt/s');
 }
开发者ID:vyserees,项目名称:mobile,代码行数:7,代码来源:home.php

示例3: mailto

 function mailto($email, $title = NULL)
 {
     // Obfuscate email address
     $email = email($email);
     $title = $title === NULL ? $email : $title;
     return '<a target="_blank" class="btn btn-lg btn-max" href="&#109;&#097;&#105;&#108;&#116;&#111;&#058;' . $email . '">' . $title . ' <i class="fa fa-envelope"></i></a>';
 }
开发者ID:bartuspan,项目名称:logo-generator,代码行数:7,代码来源:helpers.php

示例4: sendEmail

function sendEmail(&$patientInfo, &$dataLocation, &$emailTo, &$link)
{
    // start email:
    $message = 'Dear ChRIS user,' . PHP_EOL;
    $message .= 'You have a new incoming series available at:' . PHP_EOL . PHP_EOL;
    $message .= 'Output directory: ' . $dataLocation . PHP_EOL . PHP_EOL;
    if ($link != '') {
        $message .= "Please click on the following link to create a new feed for this data: " . PHP_EOL;
        $message .= $link . PHP_EOL . PHP_EOL;
    }
    // patient information
    $message .= '===== Patient =====' . PHP_EOL;
    $message .= 'ID: ' . $patientInfo['PatientID'][0] . PHP_EOL;
    $message .= 'Name: ' . $patientInfo['PatientName'][0] . PHP_EOL;
    $message .= 'Sex: ' . $patientInfo['PatientSex'][0] . PHP_EOL;
    $message .= 'BirthDate: ' . $patientInfo['PatientBirthDate'][0] . PHP_EOL . PHP_EOL;
    // patient information
    $message .= '===== Data =====' . PHP_EOL;
    $message .= 'Study Date: ' . $patientInfo['StudyDate'][0] . PHP_EOL;
    $message .= 'Study Description: ' . $patientInfo['StudyDescription'][0] . PHP_EOL;
    $message .= 'Series Description: ' . $patientInfo['SeriesDescription'][0] . PHP_EOL;
    $message .= 'Protocol: ' . $patientInfo['ProtocolName'][0] . PHP_EOL;
    $message .= 'Station: ' . $patientInfo['StationName'][0] . PHP_EOL . PHP_EOL . PHP_EOL;
    $message .= "Thank you for using ChRIS.";
    email(CHRIS_DICOM_EMAIL_FROM, $emailTo, "New dicom series has been received", $message);
}
开发者ID:masroore,项目名称:chrisreloaded,代码行数:26,代码来源:pacs.handler.php

示例5: validationmail

function validationmail($email)
{
    require_once 'mysql/mysql.php';
    require 'mysql/mysql_settings.php';
    //Build mysql connection
    $mysql = new MySQL($mysql_user, $mysql_pw, $mysql_server, $mysql_db);
    //Create request
    $request = 'INSERT INTO validationmails(email) VALUES ("' . $email . '");';
    //Perform request
    $response = $mysql->insert($request);
    //Check if request was successfull
    if (!$response) {
        $echo = mysqli_error($mysql->getCon());
    } else {
        $id = $mysql->insert_id;
    }
    return email($email, '
			Hi ' . $user . ',
			um loszulegen klick einfach auf den Link und los geht\'s!
				
			http://fragdichab.de/?p=1&id=' . $id . '&req=validation
			
			Sch�ne Gr��e,
			Ruben & Jannes
			', 'Bestaetigungsmail');
}
开发者ID:jannessm,项目名称:alqaida,代码行数:26,代码来源:functions.php

示例6: recoverPassword

 private function recoverPassword($email)
 {
     $this->_password_token = md5(uniqid($this->_data->username, true));
     $id = $this->_data->id;
     $this->_db->update('users', $id, array('password_token' => $this->_password_token));
     email($email, 'Recovering Your Password', "\n\t\t\t\t\t\t<p>Hello " . $this->_data->firstname . ",</p><br />\n\t\t\t\t\t\t<p>Click on the link below to reset your password:</p><br />\n\n\t\t\t\t\t\t<p><a href='http://localhost:8888/reset_password.php?email=" . $email . "&password_token=" . $this->_password_token . "'>http://localhost:8888/reset_password.php?email=" . $email . "&password_token=" . $this->_password_token . "</a></p><br>\n\n\t\t\t\t\t\t--Bloggr\n\t\t\t\t\t\t");
 }
开发者ID:lamwin,项目名称:bloggr,代码行数:7,代码来源:Recover.php

示例7: execute

 /**
  * @return mixed
  */
 public function execute()
 {
     $password = auth()->createPassword();
     foreach (config('pckg.auth.providers') as $providerKey => $providerConfig) {
         if (!$providerConfig['forgotPassword']) {
             continue;
         }
         /**
          * Create and set new provider.
          */
         $provider = Reflect::create($providerConfig['type'], [auth()]);
         $provider->setEntity($providerConfig['entity']);
         /**
          * If user doesnt exists, don't proceed with execution.
          */
         if (!($user = $provider->getUserByEmail(post('email')))) {
             continue;
         }
         $user->password = sha1($password . $providerConfig['hash']);
         $user->save();
         /**
          * Send email via queue.
          */
         email('password-update', new User($user), ['data' => ['password' => $password], 'fetch' => ['user' => [$user->getEntityClass() => $user->id]]]);
         return $this->successful();
     }
     return $this->error();
 }
开发者ID:pckg,项目名称:auth,代码行数:31,代码来源:SendNewPassword.php

示例8: __destruct

 function __destruct()
 {
     if (count($this->list_error) > 0) {
         print_r($this->list_error);
         email(ADMIN_EMAIL, 'DB Error', print_r($this->list_error, true));
     }
     @mysql_close($this->link);
 }
开发者ID:Edgardoweb,项目名称:cedula-api,代码行数:8,代码来源:classDBAndUser.php

示例9: email_post

function email_post($to, $subject = false, $from = false)
{
    global $_POST;
    if (!$subject) {
        $subject = "Form Submission from " . $_josh["domainname"];
    }
    email($to, draw_page($subject, draw_array($_POST), false, true), $subject, $from);
}
开发者ID:joshreisner,项目名称:hcfa-cc,代码行数:8,代码来源:email.php

示例10: register_user

function register_user($register_data)
{
    array_walk($register_data, 'array_sanitize');
    $register_data['password'] = md5($register_data['password']);
    $fields = '`' . implode('`, `', array_keys($register_data)) . '`';
    $data = '\'' . implode('\', \'', $register_data) . '\'';
    mysql_query("INSERT INTO `users` ({$fields}) VALUES ({$data})");
    email($register_data['email'], 'Activate your account', "Hello " . $register_data['first_name'] . ",\n\nYou need to activate your account to access student portal, So use the link Below:\n\n\n http://www.utkalplacement.org/app/usr/activate.php?email=" . $register_data['email'] . "&email_code=" . $register_data['email_code'] . "\n\n\n ** Please upload your photo in Edit profile option  after log in.\n\n\n\n- Placement Cell, \n Utkal University");
}
开发者ID:prabhat2233,项目名称:UtkalPortal,代码行数:9,代码来源:users.php

示例11: register_user

function register_user($register_data)
{
    array_walk($register_data, 'array_sanitize');
    $register_data['password'] = md5($register_data['password']);
    $fields = '`' . implode('`, `', array_keys($register_data)) . '`';
    $data = '\'' . implode('\', \'', $register_data) . '\'';
    mysql_query("INSERT INTO `login_admin` ({$fields}) VALUES ({$data}) ");
    email($rgister_data['email'], 'Activate your account', "Hello " . $register_data['first_name'] . ",\n\nYou need to activate your account, please use the link below:\n\n http://trendmashing.gopagoda.com/Login/activate.php?email=" . $register_data['email'] . "&email_code=" . $register_data['email_code'] . "\n\n link - TrendMash\n\t");
}
开发者ID:briannci,项目名称:CollegeWork,代码行数:9,代码来源:users.php

示例12: form_process

function form_process()
{
    global $to, $subject;
    //$errors = validate_form_items();
    if (count($errors) == 0) {
        $errors[] = email(trim($_POST["email"]), $to, $subject, $_POST["messages"]);
    }
    print_error($errors);
}
开发者ID:BGCX067,项目名称:faddsds2-svn-to-git,代码行数:9,代码来源:email_form_process.php

示例13: wrapHtml

 function wrapHtml($content)
 {
     $this->document->addCrumb('forside', $this->url());
     $model = array('content' => $content, 'navigation' => array(array('url' => $this->url('/faciliteter'), 'navigation_name' => 'Rundvisning'), array('url' => $this->url('/fotogalleri'), 'navigation_name' => 'Højdepunkter'), array('url' => $this->url('/nyheder'), 'navigation_name' => 'Nyheder'), array('url' => $this->url('/fag'), 'navigation_name' => 'Fag'), array('url' => $this->url('/langekurser'), 'navigation_name' => 'Lange kurser'), array('url' => $this->url('/langekurser/rejser'), 'navigation_name' => 'Rejser'), array('url' => $this->url('/kortekurser'), 'navigation_name' => 'Korte kurser'), array('url' => $this->url('/underviser'), 'navigation_name' => 'Lærerkræfter'), array('url' => $this->url('/info'), 'navigation_name' => 'Info og filosofi'), array('url' => $this->url('/bestilling'), 'navigation_name' => 'Bestilling')), 'url' => $this->url('/'), 'site_info' => '<a href="' . $this->url('/kontakt') . '">Vejle Idrætshøjskole</a> Ørnebjervej 28 7100 Vejle Tlf. 7582 0811 ' . email('kontor@vih.dk'), 'name' => 'Vejle Idrætshøjskole', 'navigation_section' => array(array('url' => 'http://vih.dk/kursuscenter/', 'navigation_name' => 'Kursuscenter'), array('url' => 'http://vih.dk/elevforeningen/', 'navigation_name' => 'Elevforeningen'), array('url' => 'http://www.vies.dk/', 'navigation_name' => 'Efterskole')), 'trail' => $this->document->trail, 'title' => $this->document->title());
     $tpl = $this->template->create('body');
     $content = $tpl->render($this, $model);
     $data = array('content' => $content, 'meta' => $this->document->meta, 'styles' => $this->document->styles(), 'scripts' => $this->document->scripts(), 'feeds' => $this->document->rss, 'body_id' => $this->document->body_id, 'protocol' => $this->document->protocol, 'body_class' => $this->document->body_class, 'theme' => $this->document->theme, 'title' => $this->document->title());
     $tpl = $this->template->create('main');
     return $tpl->render($this, $data);
 }
开发者ID:vih,项目名称:vih.dk,代码行数:10,代码来源:Root.php

示例14: exception_handler

/**
 * Global exception handler
 */
function exception_handler($exception)
{
    // TODO: Error logging via email, page redirect on error
    try {
        uses_system('mail/mail');
        $session = Session::Get();
        email('error/exception', 'donotreply@massify.com', 'wtf@massifycorp.com', '[EXCEPTION] ' . $exception->getMessage(), array('session' => $session, 'exception' => $exception));
    } catch (Exception $ex) {
    }
    include PATH_PUB . 'ohnoes.html';
}
开发者ID:jawngee,项目名称:HeavyMetal,代码行数:14,代码来源:production.php

示例15: lost

 public function lost()
 {
     call("usuarios", "brain");
     $usuarios = new _usuarios();
     $senha = $usuarios->Read("password", "email like '" . $_POST['e'] . "'");
     if ($senha['password'] == "") {
         echo "O seu email não consta no nosso cadastro.";
     } else {
         echo email($_POST['e'], "SENHA RECUPERADA", "3PIXELS", "contato@studio3pixels.com", "Sua senha é: " . $senha['password']);
     }
 }
开发者ID:andersonsousa,项目名称:Diferente.tv,代码行数:11,代码来源:auth.php


注:本文中的email函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。