hpez/url-shortener

A url shortener for laravel

v0.1.8 2020-09-22 08:31 UTC

This package is auto-updated.

Last update: 2024-05-22 17:00:19 UTC


README

A simple url shortener package for laravel

Install using:

composer require hpez/url-shortener

Then add the Alias in config/app.php:

        'UrlShortener' => \Hpez\UrlShortener\Facades\UrlShortener::class,

And the service provider if not added automatically:

        Hpez\UrlShortener\UrlShortenerServiceProvider::class

And then run the migrations:

php artisan migrate        

Usage:

    $shortenedUrl = UrlShortener::shorten('/test'); // returns '/u/70aa139e2c' e.g.