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


PHP FSS_Helper::ObjectToArray方法代码示例

本文整理汇总了PHP中FSS_Helper::ObjectToArray方法的典型用法代码示例。如果您正苦于以下问题:PHP FSS_Helper::ObjectToArray方法的具体用法?PHP FSS_Helper::ObjectToArray怎么用?PHP FSS_Helper::ObjectToArray使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在FSS_Helper的用法示例。


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

示例1: EMail_To_Ticket_Handler

 /**
  * Emails to admins
  */
 static function EMail_To_Ticket_Handler($template, &$ticket, $subject, $body, $files = array())
 {
     $ticket = FSS_Helper::ObjectToArray($ticket);
     $mailer = new FSSMailer();
     self::Ticket_To_Admins($mailer, $ticket);
     $lang = "";
     if ($ticket['admin_id'] > 0) {
         $user = JFactory::getUser($ticket['admin_id']);
         $lang = $user->getParam('language');
     }
     //$lang =
     // parse template etc
     $template = self::Get_Template($template, $lang);
     $email = self::ParseTemplate($template, $ticket, $subject, $body, $template['ishtml']);
     $mailer->isHTML($template['ishtml']);
     $mailer->setSubject($email['subject']);
     $mailer->setBody($email['body']);
     if (FSS_Settings::get('support_email_file_handler') == 1) {
         $mailer->addFiles($files);
     }
     $mailer->addDebug('Ticket', $ticket);
     $mailer->send();
 }
开发者ID:vstorm83,项目名称:propertease,代码行数:26,代码来源:email.php

示例2: EMail_To_Ticket_User

 static function EMail_To_Ticket_User($template_name, &$ticket, $subject = "", $body = "", $files = array())
 {
     $cc_admins = $template_name == "email_on_create" || $template_name == "email_on_create_unreg" || $template_name == "email_unreg_passwords" ? false : true;
     $is_create = $template_name == "email_on_create" || $template_name == "email_on_create_unreg" ? true : false;
     $ticket = FSS_Helper::ObjectToArray($ticket);
     $db = JFactory::getDBO();
     $mailer = new FSSMailer();
     self::Ticket_To_Users($mailer, $ticket);
     // Add bcc to admins if set up. Dont send when creating a ticket as they get notifications from
     // Admin_Create function
     if ($cc_admins && FSS_Settings::get('support_email_bcc_handler')) {
         self::Ticket_To_Admins($mailer, $ticket);
     }
     // build template and parse it
     $template = self::Get_Template($template_name, $ticket['lang']);
     $email = self::ParseTemplate($template, $ticket, $subject, $body, $template['ishtml'], true);
     // set result to mailer
     $mailer->isHTML($template['ishtml']);
     $mailer->setSubject($email['subject']);
     $mailer->setBody($email['body']);
     // Only send attachments to users when creating if the ticket is created by an admin
     $session = JFactory::getSession();
     if (FSS_Settings::get('support_email_file_user') && (!$is_create || $session->Get('admin_create') > 0)) {
         $mailer->addFiles($files);
     }
     // add debug info
     $mailer->addDebug('Ticket', $ticket);
     // send actual mail
     self::Send($mailer);
 }
开发者ID:vstorm83,项目名称:propertease,代码行数:30,代码来源:jomsocial.php


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