php - make element dragable in Yii2 -
i want make draggable element in yii2 advance application. in php or html example http://jqueryui.com/draggable . try in yii2 didn't work. can me please? view page code. <?php /* @var $this yii\web\view */ use yii\helpers\html; $this->title = 'generate table'; $this->params['breadcrumbs'][] = $this->title; ?> <div class="site-generatetable"> <h1><?= html::encode($this->title) ?></h1> <p>test drag , drop function</p> <div id="draggable" class="ui-widget-content"> <p>drag me around</p> </div> </div> <style> #draggable { width: 150px; height: 150px; padding: 0.5em; } </style> <script> $(function() { $( "#draggable" ).draggable(); }); </script> and application asset this <?php namespace frontend\assets; use yii\web\assetbundle; /** * main frontend application asset bundle....