• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP message类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: _checkForCorrectMessageType

 /**
  * Assert that the SNS message type is notification
  *
  * @param message $snsJsonMsg convertedJsonMsg
  *
  * @throws OffAmazonPaymentsNotifications_InvalidMessageException if not correct type
  *
  * @return void if correct type
  */
 private static function _checkForCorrectMessageType($snsJsonMsg)
 {
     $type = $snsJsonMsg->getMandatoryField("Type");
     if (strcasecmp($type, "Notification") != 0) {
         throw new OffAmazonPaymentsNotifications_InvalidMessageException("Error with SNS Notification - unexpected message with Type of " . $type);
     }
 }
开发者ID:brenot,项目名称:forumdesenvolvimento,代码行数:16,代码来源:SnsMessageParser.php


示例2: getUnreadMessages

function getUnreadMessages($inUserID)
{
    if (isset($_SESSION['userid'])) {
        $messages = array();
        $messageid;
        $dbhandle = db_connect();
        $stmt = $dbhandle->stmt_init();
        //Get all messages from/to this user that are unread
        $stmt->prepare("SELECT MessageID, Time FROM Messages WHERE SenderID=? AND ReceiverID=? AND ReadFlag=0 ORDER BY Time");
        $stmt->bind_param("ii", $inUserID, $_SESSION['userid']);
        $stmt->execute();
        $stmt->store_result();
        $stmt->bind_result($messageid, $temptime);
        //Add each resulting message to the array to return
        //Mark the message as read
        while ($stmt->fetch()) {
            $message = new message();
            $message->getFromDB($messageid);
            $message->markRead();
            array_push($messages, $message);
        }
        $stmt->close();
        $dbhandle->close();
        return $messages;
    }
}
开发者ID:sammyr2011,项目名称:Task_Master,代码行数:26,代码来源:message_lister.php


示例3: module_message_edit

function module_message_edit()
{
    global $global, $smarty;
    $obj = new message();
    $obj->set_where('mes_id = ' . $global['id']);
    $smarty->assign('message', $obj->get_one());
}
开发者ID:jechiy,项目名称:xiu-cms,代码行数:7,代码来源:message_edit.php


示例4: removeava

 public function removeava()
 {
     if (isset($_GET['avi_id']) && isset($_GET['cli_id'])) {
         $idAvis = $_GET['avi_id'];
         $idUser = $_GET['cli_id'];
         $st = db()->prepare("DELETE FROM T_J_AVISABUSIF_AVA WHERE avi_id=:avi and cli_id=:cli");
         $st->bindParam(':avi', $idAvis);
         $st->bindParam(':cli', $idUser);
         $st->execute();
         $m = new message();
         $m->setFlash("L'avis abusif a été ignoré", "success");
         header("Refresh:0; url=../Sprint/?r=src");
         //            $id = $_GET['avi_id'];
         //            $avis = new T_E_AVIS_AVI($id);
         //            if($avis->avi_id == null){
         //                $m = new message();
         //                $m->setFlash("Cet avis n'existe pas");
         //                header("Refresh:0; url=../Sprint/?r=src");
         //            } else {
         //                $avis->deleteAllAva();
         //                $m = new message();
         //                $m->setFlash("l'avis a bien été supprimé","success");
         //                header("Refresh:0; url=../Sprint/?r=src");
         //
         //            }
     }
 }
开发者ID:ColinPeyrat,项目名称:scrum-ecommerce,代码行数:27,代码来源:SERVICE_COMMUNICATIONController.php


示例5: addPhoto

 public static function addPhoto($jeu_id, $pho_url)
 {
     $st = db()->prepare("insert into t_e_photo_pho(jeu_id,pho_url) values(" . $jeu_id . ",'" . $pho_url . "')");
     $st->execute();
     $m = new message();
     $m->setFlash("Upload réussi", "success");
 }
开发者ID:ColinPeyrat,项目名称:scrum-ecommerce,代码行数:7,代码来源:T_E_PHOTO_PHO.php


示例6: addVideo

 public static function addVideo($jeu_id, $vid_url)
 {
     $st = db()->prepare("insert into t_e_video_vid(jeu_id,vid_url) values(" . $jeu_id . ",'" . $vid_url . "')");
     $st->execute();
     $m = new message();
     $m->setFlash("Upload réussi", "success");
 }
开发者ID:ColinPeyrat,项目名称:scrum-ecommerce,代码行数:7,代码来源:T_E_VIDEO_VID.php


示例7: addMessages

 private function addMessages($project_id, $messagesArray)
 {
     $addMessage = new message();
     $userObj = new user();
     foreach ($messagesArray->{'post'} as $message) {
         $insid = 0;
         $title = $message->{'title'};
         $text = $message->{'body'};
         $uid = $message->{'author-id'};
         $user = $this->peopleHash["{$uid}"];
         $userProfile = $userObj->getProfile($user);
         $username = $userProfile["name"];
         $replies = $message->{'comments'};
         $insid = $addMessage->add($project_id, $title, $text, "", $user, $username, 0, 0);
         if ($insid > 0) {
             ++$this->msgCount;
             if (count($replies) > 0) {
                 foreach ($replies->{'comment'} as $reply) {
                     ++$this->msgCount;
                     $replytext = $reply->{"body"};
                     $ruid = $reply->{'author-id'};
                     $ruser = $this->peopleHash["{$ruid}"];
                     $ruserProfile = $userObj->getProfile($ruser);
                     $rusername = $ruserProfile["name"];
                     $addMessage->add($project_id, $replytext, $replytext, "", $ruser, $rusername, $insid, 0);
                 }
             }
         }
     }
 }
开发者ID:janvalentik,项目名称:Collabtive,代码行数:30,代码来源:class.importer.php


示例8: signal

 public function signal()
 {
     if (isset($_GET['id_avi'])) {
         if (!isset($_SESSION['user'])) {
             $m = new message();
             $m->setFlash("Vous devez etre connecté pour signaler un commentaire");
             $c = new T_E_CLIENT_CLIController();
             $c->render("login");
         } else {
             $allAvas = T_J_AVISABUSIF_AVA::FindAllByIdAvis($_GET['id_avi']);
             $alreadySignal = false;
             foreach ($allAvas as $ava) {
                 if ($ava->T_E_CLIENT_CLI->cli_id == $_SESSION['user']->cli_id) {
                     $alreadySignal = true;
                 }
             }
             if ($alreadySignal) {
                 $m = new message();
                 $m->setFlash("Vous avez déja signaler ce commentaire, merci d'attendre que le service vente prenne en compte votre requête");
                 header("Refresh:0; url=../Sprint/?r=jeu");
             } else {
                 T_J_AVISABUSIF_AVA::insertNewAva($_GET['id_avi'], $_SESSION['user']->cli_id);
                 $m = new message();
                 $m->setFlash("Le commentaire a bien été signalé", 'success');
                 header("Refresh:0; url=../Sprint/?r=jeu");
             }
         }
     }
 }
开发者ID:ColinPeyrat,项目名称:scrum-ecommerce,代码行数:29,代码来源:T_E_AVIS_AVIController.php


示例9: module_message_main

function module_message_main()
{
    global $global, $smarty;
    $obj = new message();
    $obj->set_page_size(5);
    $obj->set_page_num($global['page']);
    $sheet = $obj->get_sheet();
    set_link($obj->get_page_sum());
    $smarty->assign('message', $sheet);
}
开发者ID:jechiy,项目名称:xiu-cms,代码行数:10,代码来源:message_main.php


示例10: xsend

 public function xsend()
 {
     $message_configs['appid'] = $this->appid;
     $message_configs['appkey'] = $this->appkey;
     if ($this->sign_type != '') {
         $message_configs['sign_type'] = $this->sign_type;
     }
     $message = new message($message_configs);
     return $message->xsend($this->buildRequest());
 }
开发者ID:xueron,项目名称:SUBMAIL_PHP_SDK,代码行数:10,代码来源:messagexsend.php


示例11: unsubscribe

 public function unsubscribe()
 {
     $message_configs['appid'] = $this->appid;
     $message_configs['appkey'] = $this->appkey;
     if ($this->sign_type != '') {
         $message_configs['sign_type'] = $this->sign_type;
     }
     $addressbook = new message($message_configs);
     return $addressbook->unsubscribe($this->buildRequest());
 }
开发者ID:xueron,项目名称:SUBMAIL_PHP_SDK,代码行数:10,代码来源:addressbookmessage.php


示例12: removeRelay

 public function removeRelay()
 {
     if (isset($_SESSION['user'])) {
         if (isset($_GET['rel_id'])) {
             T_J_RELAISCLIENT_REC::removeRelayClient($_SESSION['user']->cli_id, $_GET['rel_id']);
             $m = new message();
             $m->setFlash('Le relais a bien été supprimé', 'success');
             header("Refresh:0; url=../Sprint/?r=cli/myRelay");
         }
     }
 }
开发者ID:ColinPeyrat,项目名称:scrum-ecommerce,代码行数:11,代码来源:T_J_RELAISCLIENT_RECController.php


示例13: send

 public function send($template, $data, $callback)
 {
     $builder = $this->mailer->MessageBuilder();
     $message = new message($builder);
     $message->from($this->config->get('mail.from'));
     $this->view->appendData($data);
     $message->body($this->view->render($template));
     call_user_func($callback, $message);
     $domain = $this->config->get('mail.domain');
     $this->mailer->post("{$domain}/messages", $builder->getMessage());
 }
开发者ID:yigitemre,项目名称:BauBoxProject,代码行数:11,代码来源:mailer.php


示例14: shutdown

 public static function shutdown()
 {
     $error = error_get_last();
     if ($error['message']) {
         $message = new message($error['message'], self::$levels['fatal']);
         $message->setFile($error['file']);
         $message->setLine($error['line']);
     } else {
         $message = new message("Exit", self::$levels['notice']);
     }
     self::_log($message);
 }
开发者ID:nastradamus39,项目名称:logger_client,代码行数:12,代码来源:httplogger.php


示例15: show_mail

 private function show_mail($mail)
 {
     $message = new message($mail["message"]);
     $mail["message"] = $message->unescaped_output();
     if ($mail["to_user_id"] == $this->user->id) {
         $this->title = "Inbox";
     } else {
         $this->title = "Sentbox";
         $back = "/sent";
     }
     $actions = show_boolean($mail["to_user_id"] == $this->user->id);
     $this->output->record($mail, "mail", array("actions" => $actions, "back" => $back));
 }
开发者ID:shannara,项目名称:banshee,代码行数:13,代码来源:mailbox.php


示例16: reply_mes

function reply_mes()
{
    global $smarty, $lang;
    $mes_id = post('mes_id');
    $mes_reply = post('mes_reply');
    $obj = new message();
    $obj->set_value('mes_reply', $mes_reply);
    $obj->set_where("mes_id = {$mes_id}");
    $obj->edit();
    $smarty->assign('info_text', '回复留言成功');
    $smarty->assign('link_text', $lang['return_list']);
    $smarty->assign('link_href', url(array('channel' => 'service', 'mod' => 'message_sheet')));
}
开发者ID:jechiy,项目名称:xiu-cms,代码行数:13,代码来源:deal.php


示例17: findBySelection

 public function findBySelection()
 {
     if (isset($_POST["id_console"])) {
         $id_console = $_POST["id_console"];
         $data = T_E_JEUVIDEO_JEU::findBySelection($id_console);
         if ($data == null) {
             $m = new message();
             $m->setFlash("Aucun résultat pour cette recherche.", "warning");
         }
         $this->render("find", T_E_JEUVIDEO_JEU::findBySelection($id_console));
     } else {
         $this->render("find");
     }
 }
开发者ID:ColinPeyrat,项目名称:scrum-ecommerce,代码行数:14,代码来源:T_E_JEUVIDEO_JEUController.php


示例18: index

 public function index()
 {
     $form = $this->_get_form();
     if (request::method() == "post") {
         access::verify_csrf();
         if ($form->validate()) {
             module::set_var("strip_exif", "exiv_path", $_POST['exiv_path']);
             if ($_POST['exif_tags'] != "") {
                 module::set_var("strip_exif", "exif_remove", isset($_POST['exif_remove']) ? $_POST['exif_remove'] : false);
                 module::set_var("strip_exif", "exif_tags", $_POST['exif_tags']);
             } else {
                 module::set_var("strip_exif", "exif_remove", false);
                 module::set_var("strip_exif", "exif_tags", self::$defExifTags);
             }
             if ($_POST['iptc_tags'] != "") {
                 module::set_var("strip_exif", "iptc_remove", isset($_POST['iptc_remove']) ? $_POST['iptc_remove'] : false);
                 module::set_var("strip_exif", "iptc_tags", $_POST['iptc_tags']);
             } else {
                 module::set_var("strip_exif", "iptc_remove", false);
                 module::set_var("strip_exif", "iptc_tags", self::$defIptcTags);
             }
             if (isset($_POST['verbose'])) {
                 module::set_var("strip_exif", "verbose", $_POST['verbose']);
             }
             message::success(t("Settings have been saved"));
             url::redirect("admin/strip_exif");
         } else {
             message::error(t("There was a problem with the submitted form. Please check your values and try again."));
         }
     }
     print $this->_get_view();
 }
开发者ID:webmatter,项目名称:gallery3-contrib,代码行数:32,代码来源:admin_strip_exif.php


示例19: handler

 public function handler()
 {
     access::verify_csrf();
     $form = $this->_get_form();
     if ($form->validate()) {
         module::set_var("social_share", "general_impage_only", $form->general_settings->general_impage_only->value);
         module::set_var("social_share", "facebook_share_enabled", $form->facebook_share_settings->facebook_share_enabled->value);
         module::set_var("social_share", "facebook_share_layout", $form->facebook_share_settings->facebook_share_layout->value);
         module::set_var("social_share", "facebook_share_link_text", $form->facebook_share_settings->facebook_share_link_text->value);
         module::set_var("social_share", "facebook_like_enabled", $form->facebook_like_settings->facebook_like_enabled->value);
         module::set_var("social_share", "facebook_like_appId", $form->facebook_like_settings->facebook_like_appId->value);
         module::set_var("social_share", "facebook_like_adminId", $form->facebook_like_settings->facebook_like_adminId->value);
         module::set_var("social_share", "facebook_like_site_name", $form->facebook_like_settings->facebook_like_site_name->value);
         module::set_var("social_share", "facebook_like_code_type", $form->facebook_like_settings->facebook_like_code_type->value);
         module::set_var("social_share", "facebook_like_show_faces", $form->facebook_like_settings->facebook_like_show_faces->value, true);
         module::set_var("social_share", "facebook_like_send", $form->facebook_like_settings->facebook_like_send->value, true);
         module::set_var("social_share", "facebook_like_action", $form->facebook_like_settings->facebook_like_action->value);
         module::set_var("social_share", "facebook_like_layout", $form->facebook_like_settings->facebook_like_layout->value);
         module::set_var("social_share", "google_enabled", $form->google_settings->google_enabled->value);
         module::set_var("social_share", "google_size", $form->google_settings->google_size->value);
         module::set_var("social_share", "google_annotation", $form->google_settings->google_annotation->value);
         module::set_var("social_share", "pinterest_enabled", $form->pinterest_settings->pinterest_enabled->value);
         module::set_var("social_share", "pinterest_count_location", $form->pinterest_settings->pinterest_count_location->value);
         module::set_var("social_share", "twitter_enabled", $form->twitter_settings->twitter_enabled->value);
         module::set_var("social_share", "twitter_count_location", $form->twitter_settings->twitter_count_location->value);
         module::set_var("social_share", "twitter_size", $form->twitter_settings->twitter_size->value);
         message::success(t("Your settings have been saved."));
         url::redirect("admin/social_share");
     }
     print $this->_get_view($form);
 }
开发者ID:webmatter,项目名称:gallery3-contrib,代码行数:31,代码来源:admin_social_share.php


示例20: saveprefs

 public function saveprefs()
 {
     // Prevent Cross Site Request Forgery
     access::verify_csrf();
     // Figure out which boxes where checked
     $dlLinks_array = Input::instance()->post("DownloadLinkOptions");
     $fButton = false;
     $download_original_button = false;
     for ($i = 0; $i < count($dlLinks_array); $i++) {
         if ($dlLinks_array[$i] == "fButton") {
             $fButton = true;
         }
     }
     if (module::is_active("keeporiginal")) {
         $keeporiginal_array = Input::instance()->post("DownloadOriginalOptions");
         for ($i = 0; $i < count($keeporiginal_array); $i++) {
             if ($keeporiginal_array[$i] == "DownloadOriginalImage") {
                 $download_original_button = true;
             }
         }
         module::set_var("downloadfullsize", "DownloadOriginalImage", $download_original_button);
     }
     // Save Settings.
     module::set_var("downloadfullsize", "fButton", $fButton);
     message::success(t("Your Selection Has Been Saved."));
     // Load Admin page.
     $view = new Admin_View("admin.html");
     $view->content = new View("admin_downloadfullsize.html");
     $view->content->downloadlinks_form = $this->_get_admin_form();
     print $view;
 }
开发者ID:webmatter,项目名称:gallery3-contrib,代码行数:31,代码来源:admin_downloadfullsize.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP message_box类代码示例发布时间:2022-05-23
下一篇:
PHP menus类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap