innoboxrr/support
| Install | |
|---|---|
composer require innoboxrr/support |
|
| Latest Version: | 2.1.1 |
| PHP: | ^8.3 |
| License: | MIT |
| Last Updated: | Sep 14, 2026 |
| Links: | GitHub · Packagist |
Support
Shared helpers used across the Innobox R&R Laravel packages.
This is the utility layer the other packages depend on — HTTP handling, request formatting, phone normalisation and a small data container. It is published because the packages need it, not because it is a product.
What is inside
| Component | Purpose |
|---|---|
Helpers/HttpHelper |
getSubdomain($host, $mainDomain): the subdomain of a host. Without $mainDomain it reads config('app.app_host'), which Laravel doesn't define — set it or pass the domain |
Helpers/RequestHelper |
Reading and normalising incoming request data |
Http/Requests/RequestFormater |
Flattens nested form data with underscores (seo.title → seo_title) so it can be stored as flat metas; see below |
Jobs/DispatchJob |
Generic queued dispatch used by dependent packages |
Utils/DataContainer |
A simple typed container for passing structured data around |
Utils/PhoneFormatter |
Phone number normalisation, Mexico-aware |
It also registers the standard service providers (App, Auth, Event, Route) that the dependent packages hook into.
Nested form data and metas
A form can send groups several levels deep. RequestFormater turns them into the flat keys that a model's $editable_metas lists, so MetaOperations from innoboxrr/traits can store them:
use Innoboxrr\Support\Http\Requests\RequestFormater;
RequestFormater::flatten(['seo' => ['title' => 'T', 'og' => ['image' => 'x.png']]]);
// ['seo_title' => 'T', 'seo_og_image' => 'x.png']
$article->update_metas(RequestFormater::flatten($request->all()), ArticleMeta::class, 'article_id');
- Lists (
['a', 'b']) and lists ofvalueobjects (emails, phones) are kept whole and stored as JSON. - An empty group (
'seo' => []) and empty values are kept, so a form can clear them:update_metasdeletes a meta whose value is empty. - If two keys end up the same, the first one wins.
RequestFormater::format($request)replaces the request's data in place; validation rules that run afterwards must use the flattened names.
Should you install this directly?
Usually not. It arrives as a dependency of the package you actually wanted — deals, consultant-manager, omni-billing and others. Install it on its own only if you want PhoneFormatter or DataContainer in isolation.
composer require innoboxrr/support
php artisan vendor:publish --provider="Innoboxrr\Support\Providers\AppServiceProvider" --tag=config
Full documentation of the ecosystem, in Spanish and English: https://innoboxrr.github.io/docs/paquetes/support-traits-search.
Part of Innobox R&R — 52 open-source packages extracted from production work. innobox.systems
Related Packages
Powerful PHP database abstraction layer (DBAL) with many features for database s...
Laravel Serializable Closure provides an easy and secure way to serialize closur...
Cli error handling for console/command-line PHP applications.
Version History
| Version | Released | PHP | Laravel | License |
|---|---|---|---|---|
| 2.1.1 | ^8.3 | ^13.0 | MIT | |
| 2.1.0 | ^8.3 | ^13.0 | MIT | |
| 2.0.0 | ^8.3 | ^13.0 | MIT | |
| 1.0.14 | MIT | |||
| 1.0.13 | MIT | |||
| 1.0.12 | MIT | |||
| 1.0.11 | MIT | |||
| 1.0.10 | MIT | |||
| 1.0.9 | MIT | |||
| 1.0.8 | MIT | |||
| 1.0.7 | MIT | |||
| 1.0.6 | MIT | |||
| 1.0.5 | MIT | |||
| 1.0.4 | MIT | |||
| 1.0.3 | MIT | |||
| 1.0.2 | MIT | |||
| 1.0.1 | MIT | |||
| 1.0.0 | MIT |