backendprogramer/laravel-redirect-panel
最新稳定版本:1.0.0
Composer 安装命令:
composer require backendprogramer/laravel-redirect-panel
包简介
A panel for adding redirects to the `.htaccess` file.
README 文档
README
Management panel for .htaccess file redirects.
The Redirect Panel provides the capability to manage redirects in the .htaccess file. The Redirect Panel creates a table in the database, and every redirect added is stored both in the database and in the .htaccess file. When you edit or delete a redirect, the changes are also applied to the .htaccess file.
Installation
You can install the package via composer:
composer require backendprogramer/laravel-redirect-panel
You can publish and run the migrations with:
php artisan vendor:publish --tag="laravel-redirect-panel-migrations"
php artisan migrate
You can publish the config file with:
php artisan vendor:publish --tag="laravel-redirect-panel-config"
This is the contents of the published config file:
return [ /* ----------------------------------------------------------------- | htaccess file path | ----------------------------------------------------------------- | Addressing should be done from the path of the public folder like "../../folder/.htaccess" */ 'htaccess' => '.htaccess', /* ----------------------------------------------------------------- | Locale | ----------------------------------------------------------------- | Supported locales : | 'auto', 'en', 'fa' */ 'locale' => 'auto', /* ----------------------------------------------------------------- | Direction | ----------------------------------------------------------------- | Supported directions : | 'ltr','rtl' */ 'direction' => 'ltr', /* ----------------------------------------------------------------- | redirects per page | ----------------------------------------------------------------- | This defines how many redirects are displayed per page. */ 'per-page' => 10, /* ----------------------------------------------------------------- | Colors | ----------------------------------------------------------------- | You can change color of these classes : | btn-primary, btn-danger, btn-success, btn-secondary, text-danger */ 'colors' => [ // 'fg-color' => [ // 'btn-primary' => '', // 'btn-danger' => '', // 'btn-success' => '', // 'btn-secondary' => '', // 'text-danger' => '', // ], // 'bg-color' => [ // 'btn-primary' => '', // 'btn-danger' => '', // 'btn-success' => '', // 'btn-secondary' => '', // ], // 'border-color' => [ // 'btn-primary' => '', // 'btn-danger' => '', // 'btn-success' => '', // 'btn-secondary' => '', // ], ], ];
Optionally, you can publish the views using
php artisan vendor:publish --tag="laravel-redirect-panel-views"
Optionally, you can publish the lang using
php artisan vendor:publish --tag="laravel-redirect-panel-lang"
Artisan commands
To publish the config and translations files, views and migration run this command:
php artisan redirect-panel:publish
Usage
To add to the router, please add the following code to the routes/web.php file.
Route::redirectPanel('laravel-redirect-panel');
Supported localizations
| Local | Language |
|---|---|
en |
English |
fa |
farsi |
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email backend.programer.90@gmail.com instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.
PREVIEW
统计信息
- 总下载量: 8
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-10-11


