PHPackages                             srusakov/yii2-activeresponse - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. srusakov/yii2-activeresponse

ActiveYii2-extension

srusakov/yii2-activeresponse
============================

Yii2 ajax module with active control from server side

2662PHP

Since May 19Pushed 11y ago3 watchersCompare

[ Source](https://github.com/srusakov/yii2-activeresponse)[ Packagist](https://packagist.org/packages/srusakov/yii2-activeresponse)[ RSS](/packages/srusakov-yii2-activeresponse/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

yii2-ativeresponse
==================

[](#yii2-ativeresponse)

Yii2 ajax module with active control from server side. Most of existing ajax modules for Yii2 use javascript logic. yii2-ativeresponse is controlled from the server side. All actions you add in PHP controller will be executed with corresponding jQuery function. See Usage for details.

Installation
------------

[](#installation)

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

Either run

```
$ php composer.phar require srusakov/yii2-ativeresponse "dev-master"

```

or add

```
"srusakov/yii2-ativeresponse": "dev-master"

```

to the `require` section of your `composer.json` file.

Usage
-----

[](#usage)

##### Attach `yii2-ativeresponse` to your layout file

[](#attach-yii2-ativeresponse-to-your-layout-file)

```
ActiveResponse::registerAssets($this);

```

this will register all necessary javascript files and create global javascript variables.

##### Call server (without parameters)

[](#call-server-without-parameters)

```
