PHPackages                             dominus77/yii2-basic-start - 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. [Framework](/categories/framework)
4. /
5. dominus77/yii2-basic-start

ActiveProject[Framework](/categories/framework)

dominus77/yii2-basic-start
==========================

Yii2 Start Project Basic Template

1.0.0(8y ago)6932BSD-3-ClausePHPPHP &gt;=5.5.0CI failing

Since Feb 27Pushed 5y ago2 watchersCompare

[ Source](https://github.com/Dominus77/yii2-basic-start)[ Packagist](https://packagist.org/packages/dominus77/yii2-basic-start)[ Docs](http://dominus77.github.io/yii2-basic-start)[ RSS](/packages/dominus77-yii2-basic-start/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (12)Versions (2)Used By (0)

Yii2 Start Project Basic Template
=================================

[](#yii2-start-project-basic-template)

[![Latest Stable Version](https://camo.githubusercontent.com/84df552db036987c650464a1c8e3293d3144f8ef9ba70bd06a7d23f1dba275ba/68747470733a2f2f706f7365722e707567782e6f72672f646f6d696e757337372f796969322d62617369632d73746172742f762f737461626c65)](https://packagist.org/packages/dominus77/yii2-basic-start)[![License](https://camo.githubusercontent.com/a5a8a914a541e6a7d4e9e5fe1324f2d561f62567fb66ef46ae784a7a83072d31/68747470733a2f2f706f7365722e707567782e6f72672f646f6d696e757337372f796969322d62617369632d73746172742f6c6963656e7365)](https://packagist.org/packages/dominus77/yii2-basic-start)[![build](https://github.com/Dominus77/yii2-basic-start/workflows/build/badge.svg?branch=master)](https://github.com/Dominus77/yii2-basic-start/actions?query=workflow%3Abuild)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/955596af6c9ca865d1d8dbd5e53f057f0f62905d5601ef456d17ce4a683a0840/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f446f6d696e757337372f796969322d62617369632d73746172742f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/Dominus77/yii2-basic-start/?branch=master)[![Code Intelligence Status](https://camo.githubusercontent.com/fda31257dabb727b8f41cf5a6fe5763c28470d7d90f3ad2eead5a86743ddadb1/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f446f6d696e757337372f796969322d62617369632d73746172742f6261646765732f636f64652d696e74656c6c6967656e63652e7376673f623d6d6173746572)](https://scrutinizer-ci.com/code-intelligence)[![Total Downloads](https://camo.githubusercontent.com/7066da81059dc1240971359a900f52568236d4a3e497422c5209b4ab8bbabce0/68747470733a2f2f706f7365722e707567782e6f72672f646f6d696e757337372f796969322d62617369632d73746172742f646f776e6c6f616473)](https://packagist.org/packages/dominus77/yii2-basic-start)

The application is built using basic pattern and has a modular structure.

Base components
---------------

[](#base-components)

Pages

- Home
- About
- Contact
- Check in
- Login
- Profile

Modules

- main
- users
- admin
- rbac (manage web interface)

Functional

- Reset password
- Confirmation by email
- Last visit
- Console commands
- RBAC

CSS Themes Bootstrap
--------------------

[](#css-themes-bootstrap)

The template includes the of the CSS Theme Bootstrap

Switching the theme occurs in the `app/config/web.php`

Requirements
------------

[](#requirements)

The minimum requirement by this project template that your Web server supports PHP 5.6

INSTALLATION
------------

[](#installation)

Create a project:

```
composer create-project --prefer-dist --stability=dev dominus77/yii2-basic-start basic-project
```

or clone the repository for `pull` command availability:

```
git clone https://github.com/Dominus77/yii2-basic-start.git basic-project
cd basic-project
composer install
```

Init an environment:

Run command in the root directory `public_html` of the project

if Development environment

```
composer app-init-dev
```

if Production environment

```
composer app-init-prod
```

otherwise choose Wednesday

```
php init
```

Create a database, default configure: `yii2_basic_start` in `app/config/common-local.php`

```
$config = [
    //...
    'components' => [
        'db' => [
            'dsn' => 'mysql:host=localhost;dbname=yii2_basic_start',
            //...
        ],
        //...
    ],
    //...
];
```

Apply migration:

```
composer migrate-up
```

Create users, enter the command and follow the instructions:

```
php yii users/user/create
```

- Username: set username;
- Email: set email username;
- Password: set password username (min 6 symbol);
- Status: set status username (0 - blocked, 1 - active, 2 - wait, ? - Help);

See all available commands:

```
php yii
```

### Initialize RBAC

[](#initialize-rbac)

When initialized, the user with ID:1 is assigned the SuperAdmin role.

```
composer rbac-init
```

A command to assign roles to other users:

```
php yii rbac/roles/assign

```

To untie:

```
php yii rbac/roles/revoke

```

You can then access the application through the following URL:

```
http://localhost/basic-project/web/

```

Create `.htaccess` file or add folder `app/web``

```
AddDefaultCharset utf-8
# Mod_Autoindex

  # Disable indexes
  Options -Indexes

# Mod_Rewrite

  # Enable symlinks
  Options +FollowSymlinks
  # Enable mod_rewrite
  RewriteEngine On

  # If a directory or a file exists, use the request directly
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  # Otherwise forward the request to index.php
  RewriteRule . index.php

```

Code Sniffer
------------

[](#code-sniffer)

```
composer check-style
```

TESTING
-------

[](#testing)

Create a database, default configure `yii2_basic_start_test` in `app/config/test-local.php`

```
$config = [
    //...
    'components' => [
        'db' => [
            'dsn' => 'mysql:host=localhost;dbname=yii2_basic_start_test',
            //...
        ],
        //...
    ],
    //...
];
```

Apply migration:

```
composer migrate-test-up
```

#### Run in console

[](#run-in-console)

```
composer build
composer test
```

License
-------

[](#license)

The BSD License (BSD). Please see [License File](https://github.com/Dominus77/yii2-basic-start/blob/master/LICENSE.md) for more information.

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 99.4% 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

Unknown

Total

1

Last Release

3039d ago

### Community

Maintainers

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

---

Top Contributors

[![Dominus77](https://avatars.githubusercontent.com/u/9594483?v=4)](https://github.com/Dominus77 "Dominus77 (176 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

basicdominus77yii2yii2-basic-startyii2-startframeworkyii2project templatebasicDominus77

### Embed Badge

![Health badge](/badges/dominus77-yii2-basic-start/health.svg)

```
[![Health](https://phpackages.com/badges/dominus77-yii2-basic-start/health.svg)](https://phpackages.com/packages/dominus77-yii2-basic-start)
```

###  Alternatives

[developeruz/yii-vue-app

Yii 2 + Vue.js Basic Project Template

1221.6k](/packages/developeruz-yii-vue-app)[yii2mod/base

Base application template for Yii2

531.3k](/packages/yii2mod-base)

PHPackages © 2026

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