PHPackages                             dimti/bettersettings-plugin - 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. dimti/bettersettings-plugin

ActiveOctober-plugin

dimti/bettersettings-plugin
===========================

Behaviour for OctoberCMS settings model with default values

10[1 issues](https://github.com/dimti/bettersettings-plugin/issues)PHP

Since Nov 14Pushed 4y ago1 watchersCompare

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

READMEChangelogDependenciesVersions (1)Used By (0)

Case for use that
-----------------

[](#case-for-use-that)

You love place of data in OctoberCMS settings model.

And you have default values from your site layout.

Use this package for resolve default values from setting model fields

How to use
----------

[](#how-to-use)

First installing this plugin

`composer require dimti/bettersettings-plugin`

Second - redefine behaviour in you settings model

Change

```
Settings extends model {
...

    public $implement = ['System.Behaviors.SettingsModel'];

...
}
```

To:

```
Settings extends model {
...

    public $implement = [\Dimti\BetterSettings\Behaviours\BetterSettings::class];

...
}
```

Or to:

```
...

use Dimti\BetterSettings\Behaviours\BetterSettings;

...

Settings extends model {
...

    public $implement = [BetterSettings::class];

...
}
```

And define variable `$defaults` in your setting model class.

You can also define constants for better readable values and use autocomplete in your IDE

```
use Dimti\BetterSettings\Behaviours\BetterSettings;

class Settings extends Model
{
    const SEZNAM_CID = 'seznam_cid';

    const PDF_PHONE_ONE = 'pdf_phone_one';

    const PDF_PHONE_TWO = 'pdf_phone_two';

    const PDF_PHONE_THREE = 'pdf_phone_three';

    public $defaults = [
        self::SEZNAM_CID => '100000000',
        self::PDF_PHONE_ONE => '+420 603 603 603',
        self::PDF_PHONE_TWO => '+420 723 723 723',
    ];

    public $implement = [BetterSettings::class];

    // A unique code
    public $settingsCode = 'vendor_someplugin_settings';

    // Reference to field configuration
    public $settingsFields = 'fields.yaml';
}
```

###  Health Score

10

—

LowBetter than 0% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity28

Early-stage or recently created project

 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://avatars.githubusercontent.com/u/582144?v=4)[Alexander Demidov](/maintainers/dimti)[@dimti](https://github.com/dimti)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/dimti-bettersettings-plugin/health.svg)

```
[![Health](https://phpackages.com/badges/dimti-bettersettings-plugin/health.svg)](https://phpackages.com/packages/dimti-bettersettings-plugin)
```

PHPackages © 2026

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