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


PHP qa_html_theme_base::post_meta方法代码示例

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


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

示例1: post_meta

 function post_meta($post, $class, $prefix = null, $separator = '<BR/>')
 {
     if (qa_opt('buddypress_integration_enable') && qa_opt('buddypress_display_names')) {
         if (isset($post['who']['data'])) {
             $handle = $this->who_to_handle($post['who']['data']);
             $name = bp_core_get_user_displayname($handle);
             if ($name) {
                 $post['who']['data'] = str_replace('>' . $handle . '<', ' title="@' . $handle . '">' . $name . '<', $post['who']['data']);
             }
             if ($handle && !in_array($handle, $this->bp_mentions)) {
                 // @mentions
                 $this->bp_mentions[] = $handle;
             }
         }
         if (isset($post['who_2']['data'])) {
             $handle2 = $this->who_to_handle($post['who_2']['data']);
             $name2 = bp_core_get_user_displayname($handle2);
             if ($name2) {
                 $post['who_2']['data'] = str_replace('>' . $handle2 . '<', ' title="@' . $handle2 . '">' . $name2 . '<', $post['who_2']['data']);
             }
             if ($handle2 && !in_array($handle2, $this->bp_mentions)) {
                 // @mentions
                 $this->bp_mentions[] = $handle2;
             }
         }
     }
     qa_html_theme_base::post_meta($post, $class, $prefix, $separator);
 }
开发者ID:NoahY,项目名称:q2a-buddypress,代码行数:28,代码来源:qa-bp-layer.php

示例2: post_meta

 function post_meta($post, $class, $prefix = null, $separator = '<BR/>')
 {
     if (isset($post['who']) && ($class == 'qa-q-view' && qa_opt('marker_plugin_w_qv') || $class == 'qa-q-item' && qa_opt('marker_plugin_w_qi') || $class == 'qa-a-item' && qa_opt('marker_plugin_w_a') || $class == 'qa-c-item' && qa_opt('marker_plugin_w_c'))) {
         $handle = strip_tags($post['who']['data']);
         $uid = $this->getuserfromhandle($handle);
         $image = $this->get_role_marker($uid, 2);
         $post['who']['data'] = $image . $post['who']['data'];
     }
     if (isset($post['who_2']) && ($class == 'qa-q-view' && qa_opt('marker_plugin_w_qv') || $class == 'qa-q-item' && qa_opt('marker_plugin_w_qi') || $class == 'qa-a-item' && qa_opt('marker_plugin_w_a') || $class == 'qa-c-item' && qa_opt('marker_plugin_w_c'))) {
         $handle = strip_tags($post['who_2']['data']);
         $uid = $this->getuserfromhandle($handle);
         $image = $this->get_role_marker($uid, 2);
         $post['who_2']['data'] = $image . $post['who_2']['data'];
     }
     qa_html_theme_base::post_meta($post, $class, $prefix, $separator);
 }
开发者ID:ruuttt,项目名称:question2answer_sandbox,代码行数:16,代码来源:qa-marker-layer.php


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