Advertisement
nazmiwafiy

index.php

Dec 6th, 2018
337
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.76 KB | None | 0 0
  1. <?php
  2.  
  3. use yii\helpers\Html;
  4. use yii\grid\GridView;
  5.  
  6. /* @var $this yii\web\View */
  7. /* @var $searchModel frontend\models\ContactSearch */
  8. /* @var $dataProvider yii\data\ActiveDataProvider */
  9.  
  10. $this->title = 'Contacts';
  11. $this->params['breadcrumbs'][] = $this->title;
  12. ?>
  13. <div class="contact-index">
  14.  
  15.     <h1><?= Html::encode($this->title) ?></h1>
  16.  
  17.     <p>
  18.         <?= Html::a('Create Contact', ['create'], ['class' => 'btn btn-success']) ?>
  19.     </p>
  20.     <?= GridView::widget([
  21.         'dataProvider' => $dataProvider,
  22.         'filterModel' => $searchModel,
  23.         'columns' => [
  24.             ['class' => 'yii\grid\SerialColumn'],
  25.             'name',
  26.             'email:email',
  27.             ['class' => 'yii\grid\ActionColumn'],
  28.         ],
  29.     ]); ?>
  30. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement