Example #1
0
<?php

use yii\helpers\Html;
use yii\widgets\ActiveForm;
/**
 * @var yii\web\View $this
 * @var dektrium\user\models\User $model
 */
$this->title = Yii::t('user', 'Update user');
$this->params['breadcrumbs'][] = ['label' => Yii::t('user', 'Users'), 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
\dektrium\user\assets\Passfield::register($this);
$this->registerJs(sprintf('$("#user-password").passField({"locale": "%s"});', Yii::$app->language));
?>

<h1><i class="glyphicon glyphicon-user"></i> <?php 
echo Html::encode($model->username);
?>
    <?php 
if (!$model->getIsConfirmed()) {
    ?>
        <?php 
    echo Html::a(Yii::t('user', 'Confirm'), ['confirm', 'id' => $model->id], ['class' => 'btn btn-success btn-xs', 'data-method' => 'post']);
    ?>
    <?php 
}
?>
    <?php 
if (!is_null($model->recovery_token)) {
    ?>
        <?php 
Example #2
0
 * This file is part of the Dektrium project.
 *
 * (c) Dektrium project <http://github.com/dektrium/>
 *
 * For the full copyright and license information, please view the LICENSE.md
 * file that was distributed with this source code.
 */
use yii\helpers\Html;
use yii\widgets\ActiveForm;
use dektrium\user\assets\Passfield;
/**
 * @var yii\web\View $this
 * @var yii\widgets\ActiveForm $form
 * @var dektrium\user\models\User $user
 */
Passfield::register($this);
$this->title = Yii::t('user', 'Sign up');
$this->params['breadcrumbs'][] = $this->title;
$this->registerJs(sprintf('$("#user-password").passField(%s);', json_encode(['locale' => Yii::$app->language])));
?>
<div class="row">
    <div class="col-md-4 col-md-offset-4">
        <div class="panel panel-default">
            <div class="panel-heading">
                <h3 class="panel-title"><?php 
echo Html::encode($this->title);
?>
</h3>
            </div>
            <div class="panel-body">
                <div class="alert alert-warning">