PHPackages                             keygenqt/yii2-share2 - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. keygenqt/yii2-share2

ActiveYii2-extension[Utility &amp; Helpers](/categories/utility)

keygenqt/yii2-share2
====================

An easy way to add buttons soc network share. Widget uses the Yandex Block "Share".

1.0.3(6y ago)079Apache-2.0PHPPHP &gt;=5.4.0

Since May 28Pushed 2y ago1 watchersCompare

[ Source](https://github.com/keygenqt/yii2-share2)[ Packagist](https://packagist.org/packages/keygenqt/yii2-share2)[ Docs](https://keygenqt.com/work/yii2-share2)[ RSS](/packages/keygenqt-yii2-share2/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (1)Versions (4)Used By (0)

Yii2 Share2
===========

[](#yii2-share2)

[![Packagist Downloads](https://camo.githubusercontent.com/9b086abd85cddd265b924c160ab7abcc954b0d32363460b5ae0f84c6d48e9bc2/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6b657967656e71742f796969322d7368617265323f6c6162656c3d5061636b6167697374253230446f776e6c6f616473)](https://camo.githubusercontent.com/9b086abd85cddd265b924c160ab7abcc954b0d32363460b5ae0f84c6d48e9bc2/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6b657967656e71742f796969322d7368617265323f6c6162656c3d5061636b6167697374253230446f776e6c6f616473)

An easy way to add buttons soc network share. Widget uses the Yandex [Block "Share"](https://tech.yandex.ru/share/).

 [ ![](data/demo_button.gif) ](https://old.keygenqt.com/work/yii2-share2)

#### Installation

[](#installation)

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

```
"require": {
    "keygenqt/yii2-share2": "*"
}

```

#### Usage

[](#usage)

```
use keygenqt\share2\Share2;

```

#### FYI

[](#fyi)

I did not overload all the options, there are a lot of them. Only the most basic. You can find all parameters [here](https://tech.yandex.ru/share/doc/dg/add-docpage/)

#### Options

[](#options)

```
const SOC_YA_COLLECTIONS = 'collections';
const SOC_VK = 'vkontakte';
const SOC_FACEBOOK = 'facebook';
const SOC_GPLUS = 'gplus';
const SOC_TWITTER = 'twitter';
const SOC_LINKEDIN = 'linkedin';
const SOC_VIBER = 'viber';
const SOC_WHATSAPP = 'whatsapp';
const SOC_SKYPE = 'skype';
const SOC_TELEGRAM = 'telegram';
```

Some social networks do not pay attention to the image parameter passed to them. In this case, [micro-marking](https://developer.mozilla.org/en-US/docs/Web/HTML/microformats) should be used.

#### License

[](#license)

```
Copyright 2017-2024 Vitaliy Zarubin

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

```

###  Health Score

25

—

LowBetter than 36% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

3

Last Release

2222d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/caeb1b1bfd81d9317b8317e13ff3bb8e89189e97efb42aa73a3af10f17878605?d=identicon)[keygenqt](/maintainers/keygenqt)

---

Top Contributors

[![keygenqt](https://avatars.githubusercontent.com/u/9665914?v=4)](https://github.com/keygenqt "keygenqt (5 commits)")

---

Tags

extensionsyii2yii2yandexsharesocshare2

### Embed Badge

![Health badge](/badges/keygenqt-yii2-share2/health.svg)

```
[![Health](https://phpackages.com/badges/keygenqt-yii2-share2/health.svg)](https://phpackages.com/packages/keygenqt-yii2-share2)
```

###  Alternatives

[hiqdev/yii2-yandex-metrika

Yandex.Metrika counter for Yii2 applications

101.2k](/packages/hiqdev-yii2-yandex-metrika)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
