2017 © Pedro Peláez
 

symfony-bundle short-url-bundle

Symfony Short Url bundle

image

genj/short-url-bundle

Symfony Short Url bundle

  • Friday, March 24, 2017
  • by genj
  • Repository
  • 5 Watchers
  • 1 Stars
  • 3,074 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 6 Versions
  • 1 % Grown

The README.md

GenjShortUrlBundle

Provides a way to redirect requests based on an Entity stored in the database. Features:, (*1)

  • redirect client based on the request path, e.g. '/something'
  • internal and external redirects to a path or url
  • with start/end datetime
  • configurable http status code
  • keeps the query string parameters when redirecting

Installation

Add this to your composer.json:, (*2)

    ...
    "require": {
        ...
        "genj/short-url-bundle": "dev-master"
        ...

Then run composer update. After that is done, enable the bundle in your AppKernel.php:, (*3)

# app/AppKernel.php
class AppKernel extends Kernel
{
    public function registerBundles() {
        $bundles = array(
            ...
            new Genj\ShortUrlBundle\GenjShortUrlBundle()
            ...

Finally, update your database schema:, (*4)

php app/console doctrine:schema:update

And you're done., (*5)

Usage

Add a new record to your database. Example:, (*6)

  • source: /my-old-url
  • target: /my-new-url
  • httpStatusCode: 301
  • publishAt: (now)

FAQ

My redirect is not working through app.php, but it works through app_dev.php

If you have enabled caching, it can happen that a 404 response is stored in the http cache, so clear your caches. The redirect requests themselves have private caching headers., (*7)

The Versions

24/03 2017

dev-master

9999999-dev

Symfony Short Url bundle

  Sources   Download

MIT

The Requires

 

by Choong Wei Tjeng
by Nico Kaag
by Susan Lau

url php bundle symfony routing redirect symfony-bundle shortener short genj

31/08 2015

v1.0.4

1.0.4.0

Symfony Short Url bundle

  Sources   Download

MIT

The Requires

 

by Choong Wei Tjeng
by Nico Kaag
by Susan Lau

url bundle symfony routing redirect shortener short genj

06/08 2015

v1.0.3

1.0.3.0

Symfony Short Url bundle

  Sources   Download

MIT

The Requires

 

by Choong Wei Tjeng
by Nico Kaag
by Susan Lau

url bundle symfony routing redirect shortener short genj

28/07 2015

v1.0.2

1.0.2.0

Symfony Short Url bundle

  Sources   Download

MIT

The Requires

 

by Choong Wei Tjeng
by Nico Kaag
by Susan Lau

url bundle symfony routing redirect shortener short genj

08/06 2015

v1.0.1

1.0.1.0

Symfony Short Url bundle

  Sources   Download

MIT

The Requires

 

by Choong Wei Tjeng
by Nico Kaag
by Susan Lau

url bundle symfony routing redirect shortener short genj

26/01 2015

v1.0.0

1.0.0.0

Symfony Short Url bundle

  Sources   Download

MIT

The Requires

 

by Choong Wei Tjeng
by Nico Kaag
by Susan Lau

url bundle symfony routing redirect shortener short genj