d0ggy / lara-slim-url
easy slim url
Installs: 1
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 1
pkg:composer/d0ggy/lara-slim-url
Requires
- php: >=7.0.0
Requires (Dev)
- laravel/laravel: >=5.5
- orchestra/testbench: ^3.5.0
- phpunit/phpunit: ~6.0
- squizlabs/php_codesniffer: *
This package is auto-updated.
Last update: 2025-10-10 11:18:50 UTC
README
Introduction
A Laravel package to shorten your url.
Requirements
- PHP 7.0+
- Laravel >= 5.5.0
Installing
Add the dependency to your project:
composer require d0ggy/lara-slim-url
Then publish resources using the vendor:publish command:
php artisan vendor:publish --provider="D0ggy\LaraSlimUrl\SlimUrlServiceProvider"
Next, you should migrate your database:
php artisan migrate
Usage
<?php use D0ggy\LaraSlimUrl\Facades\SlimUrl; $url = 'http://www.emard.org/harum-laborum-omnis-molestias-qui-tempora-iusto-est-maxime'; $path = SlimUrl::getSlimUrlPath($url); echo url($path);die(0);
Open http://localhost/s/{$path} in browser, you will be redirect to $url.