Download the PHP package myzero1/yii2-gridview-export without Composer

On this page you can find all versions of the php package myzero1/yii2-gridview-export. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package yii2-gridview-export

yii2-gridview-export

The export module,export gridview data to excel.use the dataProvider and columns of the gridview.

Show time

Installation

The preferred way to install this module is through composer.

Either run

or add

to the require section of your composer.json file.

Setting

Once the extension is installed, simply modify your application configuration as follows:

in main.php

in params.php

Usage

Use export widget in view

You can use it,anywhere in view as following:

Use custom router

Use the custom router in ExportController.php, as following:

Use the custom router in view, as following:

Rebuild 2.0.0

导出方式 优点 缺点 保护
文件(exportFile) 可以压缩传输 反应慢(需要完全导出为文件后再下载) 是要zip加密压缩
数据流(exportStream) 反应快(边生成边下载) 下载时间长不能压缩 使用web自动到的用户验证系统

myzero1_gdexport_streamMode 各个种参数解决yii2 AR recorder内存泄漏的优缺点

可选值 优点 缺点 注意
gc 使用gc_collect_cycles()回收内存,完全不影响现有逻辑 在某一些环境下gc_collect_cycles()不能回收内存,如php的一些docker环境,7.2-fpm-alpine,7.3-fpm-alpine ... 默认值
rewrite_class 重写vendor\yiisoft\yii2\base\Component.php,对业务处理逻辑没有影响 若在调用重写函数(rewriteClass2GC)之前已经使用了yii\base\Model或yii\db\Query 会导致重写失败,如\common\models\User::find() 若默认参数不能解决问题建议使用这个参数
curl 对原有代码没有任何侵入,通过curl分批次导出数据,每个curl请求完成自动回收内存,来达到防止内存泄漏的目的 CPU消耗大,只有actionExportStream实现了这个功能 cpu资源小的,不建议使用

*****注意

Composer中~和^的含义

release log


All versions of yii2-gridview-export with dependencies

PHP Build Version
Package Version
Requires yiisoft/yii2 Version ~2.0
nelexa/zip Version 3.3.3
jeremeamia/superclosure Version 2.4.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package myzero1/yii2-gridview-export contains the following files

Loading the files please wait ....