Download the PHP package aldaflux/seo-bundle without Composer

On this page you can find all versions of the php package aldaflux/seo-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package seo-bundle

AldafluxSeoBundle

This bundle provides a simple and flexible API to manage search engine optimization (SEO) tags in your application. Its main goal is to make it simple for you to manage the most common meta, open graph and twitter card tags and to let you configure less common ones with ease.

Build Status Scrutinizer Code Quality

Installation

Install the bundle with the command:

composer require aldaflux/seo-bundle

Register the bundle in your AppKernel:

Configuration

These configuration values are the defaults used to render your tags. See the next section to learn how to override them dynamically.

There are four sections in the config:

See "Configuration reference" to get the whole configuration.

In your config.yml:

In your view:

NOTE: _You can provide a generator name to the aldaflux_seo() twig method to render it specifically. For example, to render the basic seo generator, you can use aldaflux_seo('basic')._

The result:

NOTE: By default, the SEO generators aren't loaded if you don't require them in the config. However, if you want to use the associated generators without configuring any default values (or configuring only the general ones), you can use this notation:

Setting values dynamically

You can get the '[basic|twitter|og] as a service to set or override any values. Each value of the configuration can be overrided using a setter of the following form: $this->get('aldaflux_seo.provider.generator')->get(' [basic|twitter|og] ')->set [config field name] ( [value] )

For example, if you want to change title and robots from basic, you can do this:

Setting values from a resource

You can configure your own model classes to let the seo generators do all the work thanks to the fromResource() method. Multiple interfaces are available to help the method guess which setters to call to fill the tags.

This is an exemple for the basic generator: In your resource:

In your controller:

In your view:

The result:

There are three main interfaces, one for each generator:

These interfaces extends simpler interfaces which you can inplement instead or additionnally. For example, if you only have a meta description on your resource, you can implement DescriptionSeoInterface only to provide a description alone. This is the list of the different interfaces and what they extends:

TitleSeoInterface DescriptionSeoInterface KeywordsSeoInterface ImageSeoInterface
BasicSeoInterface X X X
OgSeoInterface X X X
TwitterSeoInterface X X X

Advanced usage

If the built-in generators don't suit your needs, LeogoutSeoBundle provides a way to create your own SEO generators. First, you have to create a class that extends the AbstractSeoGenerator class:

Then, register it as a service and add it a aldaflux_seo.generator tag and a custom alias. Don't forget the @aldaflux_seo.builder dependency:

That's it, now you can use it alongside the others:

In your controller:

In your view:

Result:

Configuration reference

Contributing

If you want to contribute (thank you!) to this bundle, here are some guidelines:

Todo

Thanks

Many thanks to the ARCANEDEV/SEO-Helper who authorized me to take some ideas from their library and to KnpMenuBundle which inspired me for the Providers APIs.


All versions of seo-bundle with dependencies

PHP Build Version
Package Version
Requires symfony/framework-bundle Version ~3.0|~4.0|~5.0|~6.0|~7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package aldaflux/seo-bundle contains the following files

Loading the files please wait ....