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


PHP User::Info方法代码示例

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


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

示例1: isset

        <section>
            <?php 
echo yii\widgets\Breadcrumbs::widget(['options' => ['class' => 'breadcrumb mb0'], 'links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : []]);
?>
            <?php 
foreach ($model as $n) {
    ?>

                <?php 
    $topicInfo = \common\models\Topic::Info($n->topic_id);
    ?>
                <?php 
    $fromUserInfo = \common\models\User::Info($n->from_user_id);
    ?>
                <?php 
    $toUserInfo = \common\models\User::Info($n->to_user_id);
    ?>

                <?php 
    if ($n->type == 1) {
        ?>
                    <article class="notice">
                        <table cellpadding="0" cellspacing="0" border="0" width="100%">
                            <tbody>
                            <tr>
                                <td width="39" align="left" valign="top">
                                    <a href="/member/<?php 
        echo $fromUserInfo['username'];
        ?>
"><img src="<?php 
        echo $fromUserInfo['avatar24'];
开发者ID:advance100,项目名称:yunjianyi,代码行数:31,代码来源:notice.php

示例2: isset

        <div class="col-md-9">
            <section>
                <?php 
echo yii\widgets\Breadcrumbs::widget(['options' => ['class' => 'breadcrumb mb0'], 'links' => isset($this->params['breadcrumbs']) ? $this->params['breadcrumbs'] : []]);
?>
                <?php 
foreach ($topic as $t) {
    ?>
                    <?php 
    $topicInfo = \common\models\Topic::Info($t['topic_id']);
    ?>
                    <?php 
    $userInfo = \common\models\User::Info($topicInfo['user_id']);
    ?>
                    <?php 
    $lastReplyUser = \common\models\User::Info($topicInfo['last_reply_user']);
    ?>
                <article class="item">
                    <table cellpadding="0" cellspacing="0" border="0" width="100%">
                        <tbody><tr>
                            <?php 
    if ($agent == 'is_iphone' || $agent == 'is_android') {
        ?>
                                <td width="24" valign="middle" align="center"><a href="/member/<?php 
        echo $userInfo['username'];
        ?>
"><img src="<?php 
        echo $userInfo['avatar24'];
        ?>
" class="img-rounded"></a></td>
                                <td width="10"></td>
开发者ID:advance100,项目名称:yunjianyi,代码行数:31,代码来源:search.php

示例3: foreach

                <?php 
    echo $model->reply;
    ?>
 回复 | 直到 <?php 
    echo Yii::$app->formatter->asRelativeTime($model->last_reply_time);
    ?>
            </div>
            <?php 
    $page = Yii::$app->request->get('page');
    $floor = ((empty($page) ? 1 : $page) - 1) * Yii::$app->params['pageSize'] + 1;
    ?>
            <?php 
    foreach ($replyList as $c) {
        ?>
                <?php 
        $userInfo = \common\models\User::Info($c->user_id);
        ?>
            <article class="topic-reply">
                <div class="topic-reply-avatar pull-left">
                    <?php 
        if ($agent == 'is_iphone' || $agent == 'is_android') {
            ?>
                        <img class="img-rounded" src="<?php 
            echo $userInfo['avatar24'];
            ?>
">
                    <?php 
        } else {
            ?>
                        <img class="img-rounded" src="<?php 
            echo $userInfo['avatar48'];
开发者ID:npk,项目名称:v2sex,代码行数:31,代码来源:view.php


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