PHPackages                             wartron/yii2-widgets-urlactive - 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. wartron/yii2-widgets-urlactive

ActiveYii2-extension

wartron/yii2-widgets-urlactive
==============================

Yii2 Widgets to override Nav and Menu isItemActive

021PHP

Since Aug 30Pushed 10y ago1 watchersCompare

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

READMEChangelogDependenciesVersions (1)Used By (0)

Yii2 Widgets - URL Active
=========================

[](#yii2-widgets---url-active)

These two simple widgets provide an easy way to have both \\yii\\widgets\\Menu and \\yii\\bootstrap\\Nav items active state depend on more than the url it is set to. We accomplish this by adding an Array of other possible url patterns that it should check against. If you look at either Menu.php or Nav.php the code is pretty simple.

An Example of using this wartron\\yii2widgets\\urlactive\\Nav widget instead of the stock for basic crud is that all the crud urls will keep the menu items state to active.

```
use wartron\yii2widgets\urlactive\Nav;

echo Nav::widget([
    'items' =>  [
        [
            'label'     => 'Gizmos',
            'url'       => ['/crud/gizmo/index'],
            'urlActive' => [
                ['/crud/gizmo/view'],
                ['/crud/gizmo/update'],
                ['/crud/gizmo/create'],
            ]
        ],
    ]
]);

```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

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

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/wartron-yii2-widgets-urlactive/health.svg)

```
[![Health](https://phpackages.com/badges/wartron-yii2-widgets-urlactive/health.svg)](https://phpackages.com/packages/wartron-yii2-widgets-urlactive)
```

PHPackages © 2026

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