0
yii2 프로젝트에서 슬라이더를 구현하려고하는데 지난 주에 yii를 사용하기 시작했습니다. 여기에서 옳은 일을하고 있다면 this 코드를 다운로드했지만 100 % 작동하지 않는 방식으로 이미지와 축소판 이미지가 표시되지만 축소판을 클릭하여 배경을 변경하지 못하고 원래 코드가 제대로 작동하고 문제는 해결할 수 없습니다. 내 YII 프로젝트에서 작업jquery 구현 전체 화면 이미지 슬라이더 yii 2 프로젝트
<?php
$dataProvider = new ActiveDataProvider([
'query' => Cake::find(),
]);
?>
<?= ListView::widget([
'dataProvider' => $dataProvider,
'itemView' => '_bolos',
'summary' => '',
'options' => [
'tag' => 'div',
'id' => 'gallery',
'class' => 'bigImages',
],
]); ?>
_bolos :
<?php
use yii\helpers\Html;
/* @var $model \app\models\Cake */
?>
<script>
<?php $this->beginBlock('page-script') ?>
(function() {
$("#gallery").fullscreenGallery();
})();
<?php $this->endBlock() ?>
</script>
<?php $this->registerJs($this->blocks['page-script']) ?>
<div id="gallery">
<div class="bigImages">
<ul>
<li> <?= Html::img($model->cakePhotos[0]->getUploadUrl('file'), ['width' => '100%']); ?></li>
</ul>
</div>
<div class="thumbnails">
<ul>
<li> <?= Html::img($model->cakePhotos[0]->getThumbUploadUrl('file')); ?></li>
</ul>
</div>
</div>