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


PHP base::get_username方法代码示例

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


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

示例1: trim

 $title = $data[$index]->title;
 $text = convert_square_bracket($text);
 $title = convert_square_bracket($title);
 if ($title) {
     $html_instance->para['HEADER'] = $title;
 }
 $userid_message = $data[$index]->user;
 $followup = $data[$index]->followup;
 $datetime = $data[$index]->datetime;
 $datetime_converted = $base_instance->convert_date($datetime);
 if ($followup == 0) {
     $color = '#dedfdf';
 } else {
     $color = '#f1f1f1';
 }
 $username = $base_instance->get_username($userid_message);
 $text = trim($text);
 $text = nl2br($text);
 if ($userid == _ADMIN_USERID && $followup != 0) {
     $delete_link = '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="' . $_SERVER['PHP_SELF'] . '?del_message=' . $ID . '&id=' . $id . '"><font color="#ff0000">Del</font></a>';
 } else {
     if ($userid == _ADMIN_USERID && $followup == 0) {
         $delete_link = '&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="show-forum.php?del_thread=' . $ID . '"><font color="#ff0000">Del</font></a>';
     } else {
         $delete_link = '';
     }
 }
 $text = $base_instance->insert_links($text);
 $all_text .= '<table bgcolor="' . $color . '" width="100%" cellspacing=0><tr><td>from <a href="show-user.php?username=' . $username . '">' . $username . '</a> <font size=1>' . $datetime_converted . '</font>' . $delete_link . '<br>' . $text . '</font></td></tr><tr bgcolor="#ffffff"><td height=3></td></tr></table>';
 if ($index == 1) {
     $all_text .= _BANNER_AD_FORUM;
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-forum-thread.php

示例2: date

$html_instance->add_parameter(array('ACTION' => 'show_content', 'ENTITY' => 'LINK', 'ORDER_COL' => 'datetime', 'MAXHITS' => 50, 'WHERE' => 'WHERE public=2', 'HEADER' => 'Public Links', 'SORTBAR' => 1, 'SORTBAR_FIELD1' => 'datetime', 'SORTBAR_NAME1' => 'Date added', 'INNER_TABLE_WIDTH' => '90%'));
$data = $html_instance->get_items();
if (!$data) {
    $base_instance->show_message('No public links added yet');
} else {
    $all_text = '<table width="100%" border=1 cellspacing=0 cellpadding=2 class="pastel">';
    $datetime = date('Y-m-d');
    for ($index = 1; $index <= sizeof($data); $index++) {
        $ID = $data[$index]->ID;
        $title = $data[$index]->title;
        $url = $data[$index]->url;
        $datetime = $data[$index]->datetime;
        $user = $data[$index]->user;
        $datetime_converted = $base_instance->convert_date($datetime);
        $url_encoded = urlencode($url);
        $username = $base_instance->get_username($user);
        if ($title) {
            $anchor = $title;
        } else {
            $anchor = 'http://' . substr($url, 0, 35);
        }
        $url2 = base64_encode($url);
        $all_text .= '

	<tr onMouseOver=\'this.style.background="#e9e9e9"\' onMouseOut=\'this.style.background="#ffffff"\'>

<td>

<strong>' . $anchor . '</strong><br><a href="load-url.php?url_encoded=' . $url2 . '" target="_blank">http://' . $url . '</a>

</td>
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-links-public.php


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