Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

yii2 a href confirm

<?php echo Html::a(Yii::t('backend', 'Delete'), ['delete', 'id' => $model->id], [
        'class' => 'btn btn-danger',
        'data' => [
            'confirm' => Yii::t('backend', 'Are you sure you want to delete this item?'),
            'method' => 'post',
        ],
    ]) ?>
 
PREVIOUS NEXT
Tagged: #href #confirm
ADD COMMENT
Topic
Name
9+2 =