2017 © Pedro Peláez
 

library laravel-title

Convenient seo-titles assembler for your web application

image

garf/laravel-title

Convenient seo-titles assembler for your web application

  • Tuesday, September 27, 2016
  • by garf
  • Repository
  • 0 Watchers
  • 4 Stars
  • 209 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 8 Versions
  • 0 % Grown

The README.md

Laravel Easy Seo Titles

Software License Laravel Version Packagist Licence, (*1)

Let your site to have nice SEO-titles on Laravel 5., (*2)

Sometimes, creating seo-titles may be tricky. Just try this package and you will be happy!, (*3)

Install

Add, (*4)

``` JSON "garf/laravel-title": "2.*", (*5)


to your `composer.json` file into `require` section. Then type in console ``` BASH $ composer update

When update completed, add to your config/app.conf file to providers section, (*6)

``` PHP 'providers' => [ // ... Garf\LaravelTitle\LaravelTitleServiceProvider::class, ], (*7)


If you want to use `Title` facade, add to same file at the `aliases` section ``` PHP 'aliases' => [ // ... 'Title' => Garf\LaravelTitle\TitleFacade::class, ]

Publishing configs

Type in your console:, (*8)

``` bash php artisan vendor:publish --provider="Garf\LaravelTitle\LaravelTitleServiceProvider", (*9)


## Usage ### Add segment to the end ``` php Title::append('Title segment');

Add segment to the beginning

``` PHP Title::prepend('Title segment');, (*10)


### Display title ``` php Title::render([$delimiter = null, $no_additions = false]);

Additionally, you can add parameters to this method:, (*11)

  • first parameter $delimiter sets the delimiter config manually. If null, will be used default delimiter
  • second parameter $no_additions will cancel suffix and prefix adding to rendered title. Also sets on_empty config parameter to empty string.

``` php Title::renderr([$delimiter = null, $no_additions = false]);, (*12)


This method is similar to `render()` method, except it will render title in reversed order. #### Check if segments exist ``` PHP Title::has();

Render custom title

``` PHP Title::make(Array $segments, [$delimiter = ' - ', $suffix = '', $prefix = '', $on_empty = '']);, (*13)


Method will return title with your own params #### Clear title stack ``` PHP Title::clear();

Method will empty title segments., (*14)

Get raw segments array

``` PHP Title::get();, (*15)


#### Get segments in JSON-object ``` PHP Title::toJson();

Plans

  • add variables to JS export
  • additional meta-tags

Contributions

Contributions are highly appreciated., (*16)

Send your pull requests to master branch., (*17)

License

The MIT License (MIT). Please see License File for more information., (*18)

The Versions

27/09 2016

dev-master

9999999-dev

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

27/09 2016

v2.0.1

2.0.1.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

17/07 2016

v2.0.0

2.0.0.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

25/12 2015

v1.2.1

1.2.1.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

25/12 2015

v1.2.0

1.2.0.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

25/12 2015

v1.1.1

1.1.1.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

07/12 2015

v1.0.1

1.0.1.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title

07/12 2015

v1.0

1.0.0.0

Convenient seo-titles assembler for your web application

  Sources   Download

MIT

The Requires

 

The Development Requires

by Dinar Garipov

laravel seo meta page title