Download the PHP package noeldemartin/laravel-semantic-seo without Composer

On this page you can find all versions of the php package noeldemartin/laravel-semantic-seo. 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 laravel-semantic-seo

Laravel Semantic SEO CI

Use this package to define Semantic SEO information through meta tags and structure data types.

Installation

Install using composer:

Usage

This package helps to scaffold Semantic HTML for a website defining two things:

The markup generated with this package should be placed on the head element. A Blade directive named semanticSEO is included with this package:

In order to define Types and Meta tags, use the SemanticSEO facade.

Using Types

Not all types are available with this package, but most common are. For example, you could define the information for a WebSite schema in your page as such:

You can place this code wherever you want, for example on the Controller handler methods.

Types automatically add meta tags that make sense, for example the code above would generate the following markup:

Other than the available types, any new types can be used with the method is like so:

To see more examples of what's available and how to use existing types, take a look to the tests in TypesTests.php file under /tests/Unit.

Using Meta tags

Some times it is necessary to define meta tags explicitly. It's also possible that for some reason you don't want to use types, in which case meta tags can be defined one by one:

Keep in mind that this package is aware of some special meta tags, for example using the "title" meta tag will actually render as a <title> tag and not <meta>. Multiple meta tags can also be defined at once (for example, if you keep the content of this tags in translation files):

To see more examples of what's available and how to use existing meta tags, take a look to the tests in MetaTagsTests.php file under /tests/Unit.

Some other special meta tags are the following:

Robots

To hide one page from crawlers, call SemanticSEO::hide() which will generate:

A middleware has also been registered in case this wants to be called from the routes file (for example, when using the view short-hand to define routes):

Sitemap and RSS

To define sitemap or rss xml locations (this could be placed in a Service Provider to prevent calling this in every controller):

Which will generate:

Canonical url

The canonical location of the page is automatically generated for every page, this can be disabled setting it as false (as well as any meta overriding by Types):

Social networks

Some short-hands are also defined for twitter and open graph, which will automatically include twitter: and og: prefixes:

Which will generate:

Extending

The basic functionallity for this package is completed, but it's lacking some type definitions. They are, however, very easy to add. In order to create a new type (or extend an existing one) three things need to be done:

Examples on how to do this can be found under the /src/Types folder, since existing classes already use this approach. I encourage you to create PRs adding extensions that live within the schema.org specification. The hierarchy of types together with their fields can be found here.


All versions of laravel-semantic-seo with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2.0
illuminate/support Version >=11.0.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 noeldemartin/laravel-semantic-seo contains the following files

Loading the files please wait ....