Download the PHP package nanson/yii2-messenger without Composer

On this page you can find all versions of the php package nanson/yii2-messenger. 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-messenger

Yii2 Messenger

Private messages module for yii2

Installing

The preferred way to install this extension is through Composer.

Migration

Configure module:

Usage

Url for contacts list: /messenger/contacts/.

Url for messages list: /messenger/contacts/messages/?id={contact_id}

Contacts widget

Display contacts list for user with last message.

Option Type Description
userId integer User ID. Default: \Yii::$app->user->id
tpl string Widget template. Default: create
options array The HTML attributes for the widget wrapper tag. Default: []
pageSize integer Contacts per page. Default: 10
defaultOrder array Default contacts order Default: ['last_message_id' => SORT_DESC]
viewRoute string Route to messages. Default: /messenger/contacts/messages
dataProviderOptions array Options for yii\data\ActiveDataProvider. Default: []
queryModifier callable Function to modify ActiveDataProvider query. Default: null
skinAsset string Skin Asset Bundles class. Default: null

Messages widget

Display user messages with current contact

Option Type Description
contactId integer Contact ID.
userId integer User ID. Default: \Yii::$app->user->id
tpl string Widget template. Default: messages
options array The HTML attributes for the widget wrapper tag. Default: []
pageSize integer Messages per page. Default: 10
defaultOrder array Default contacts order Default: ['created_at' => SORT_DESC]
dataProviderOptions array Options for yii\data\ActiveDataProvider. Default: []
queryModifier callable Function to modify ActiveDataProvider query. Default: null
skinAsset string Skin Asset Bundles class. Default: null

Add message widget

Display form to message creation.

Option Type Description
contactId integer Contact ID.
userId integer User ID. Default: \Yii::$app->user->id
tpl string Widget template. Default: create
options array The HTML attributes for the widget wrapper tag. Default: []
formOptions array The HTML attributes for the widget form. Default: []
route string Route to create message action. Default: /messenger/rest/create
skinAsset string Skin Asset Bundles class. Default: null
pjaxId string Pjax widget Id. If specified, pjax will be reloaded after message creation. Default: null
fancySelector string Fancybox selector. If specified, widget will be rendered as Fancybox. https://github.com/newerton/yii2-fancybox Default: null
fancyOptions array Fancybox widget options. Default: null

Messages counter widget

Display count unreaded messages for user.

Option Type Description
route string Route to action. Default: /messenger/rest/count
timeout integer Update timout. Default: 30
tag string Counter html tag. Default: span
options array The HTML attributes for the counter tag. Default: ['class' => 'badge']

All versions of yii2-messenger with dependencies

PHP Build Version
Package Version
Requires yiisoft/yii2 Version *
newerton/yii2-fancybox Version dev-master
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 nanson/yii2-messenger contains the following files

Loading the files please wait ....