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


PHP TribeEvents::debug方法代碼示例

本文整理匯總了PHP中TribeEvents::debug方法的典型用法代碼示例。如果您正苦於以下問題:PHP TribeEvents::debug方法的具體用法?PHP TribeEvents::debug怎麽用?PHP TribeEvents::debug使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在TribeEvents的用法示例。


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

示例1: doField

 /**
  * Determines how to handle this field's creation
  * either calls a callback function or runs this class' course of action
  * logs an error if it fails
  *
  * @since 2.0.5
  * @author jkudish
  * @return void
  */
 public function doField()
 {
     if ($this->conditional) {
         if ($this->display_callback && is_callable($this->display_callback)) {
             // if there's a callback, run it
             call_user_func($this->display_callback);
         } elseif (in_array($this->type, $this->valid_field_types)) {
             // the specified type exists, run the appropriate method
             $field = call_user_func(array($this, $this->type));
             // filter the output
             $field = apply_filters('tribe_field_output_' . $this->type, $field, $this->id, $this);
             echo apply_filters('tribe_field_output_' . $this->type . '_' . $this->id, $field, $this->id, $this);
         } else {
             // fail, log the error
             TribeEvents::debug(__('Invalid field type specified', 'tribe-events-calendar'), $this->type, 'notice');
         }
     }
 }
開發者ID:donwea,項目名稱:nhap.org,代碼行數:27,代碼來源:tribe-field.class.php

示例2: addSupportForm

 public function addSupportForm()
 {
     if (class_exists('Debug_Bar')) {
         TribeEvents::debug(self::supportForm());
     }
 }
開發者ID:Vinnica,項目名稱:theboxerboston.com,代碼行數:6,代碼來源:tribe-support.class.php

示例3: getLegacyEvents

 /**
  * Search for legacy events
  *
  * @param int $number max event count to look up
  * @return query of posts
  */
 private static function getLegacyEvents($number = -1)
 {
     // TODO: needs to account for either v1 posts or v2 'sp_events'
     $query = new WP_Query(array('post_status' => 'any', 'posts_per_page' => $number, 'meta_key' => '_EventStartDate', 'category_name' => 'Events'));
     if (count($query->posts)) {
         TribeEvents::debug(__('Install has 1 or more legacy event!', 'tribe-events-calendar'), false, 'warning');
     }
     return $query->posts;
 }
開發者ID:mpaskew,項目名稱:isc-dev,代碼行數:15,代碼來源:tribe-the-events-calendar-import.class.php


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