Yii2 Kartik Export Extension File Not Found

Hi, I’m new to Yii and I have installed the kartik export extension. When I click on export in any format, I get the following error:

File not found

Firefox can’t find the file at http://localhost/basic/web/index.php?r=industrial/index&page=1.

Check the file name for capitalization or other typing errors.

Check to see if the file was moved, renamed or deleted.

When I run this path mentioned, the page opens normally. Am I missing something here?

Please check my code:




    namespace app\controllers; 

    use yii\web\Controller; 

    use yii\data\Pagination; 

    use app\models\industrial; 

    use yii\data\ActiveDataProvider; class IndustrialController extends Controller {


    public function actionIndex()


          $query = industrial::find();

        $pagination = new Pagination([

            'defaultPageSize' => 20,

            'totalCount' => $query->count(),



        $industrials = $query->orderBy('Company_Name')






         $dataProvider=new ActiveDataProvider([

            'query' => industrial::find(),




        //return $this->render('index', ['dataProvider'=>$dataProvider]);

                 return $this->render('index', [


            'industrials' => $industrials,

            'pagination' => $pagination,






    use yii\helpers\Html; 

    use kartik\export\ExportMenu; 

    use kartik\grid\GridView; 

    use yii\widgets\LinkPager; 


    $gridColumns = [ ['class' => 'yii\grid\SerialColumn'],











    <?= ExportMenu::widget([

    'dataProvider' => $dataProvider,

    'columns' => $gridColumns,

    'fontAwesome' => true,

    'dropdownOptions' => [

    'label' => 'Export All',

    'class' => 'btn btn-default'


    ]) ?>

    <?= GridView::widget([

    'dataProvider' => $dataProvider,

    'columns' => $gridColumns,

    'export' => [

    'fontAwesome' => true,


    ]); ?>

What is the action I need to add to the controller to download the extracted file?