Download the PHP package zmark/seo-plugin without Composer

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

Sitemap disabled

Multi-lingual SEO plugin

This plugin allows to create SEO meta content for multi-lingual websites.

It also generates a multi-lingual sitemap.xml file based on desired CMS pages and others.

CMS pages, Static pages and Rainlab Blog Posts and Category pages are supported out of the box. Custom models can be easily extended. Sitemap functionality is forked from Rainlab Sitemap plugin.

It needs Rainlab Translate plugin to work.

Using the multilanguage SEO component

First you must place the Seo component in theme layout head section.

The component has two configurable properties called "prepend" and "append", if you fill them, the content will be prepended/appended to all pages titles. For example, if the page title is "Projects" and the append property is "| Site Name", the page title will show "Projects | Site Name".

Then you should create a SEO register for every page in your theme. Fill the title, description, (optional) keywords and (optional) image in each language.

Finally, show the metas in your layout like this:

Support for static pages plugin

If you use Rainlab.Pages plugin, you can also create SEO data for this static pages. You will need to add the SEO component to the static layout.

Support for Blog plugin

Blog plugin Post and Category pages are automatically supported. After installing the Blog plugin and creating post and category pages, just select the types "Blog Post" or "Blog Category" from the Type dropdown, then select one of the pages and fill the data.

You will also need to add the SeoModel component to the post or category pages (no need to set tye pageType and pageProperty options):

Support for custom models

You can create SEO Data for your own models.

Your plugin has to listen to the following events that Rainlab.Pages uses to build dynamic menus:

An example of this listeners (this code is simplified for this plugin purposes, more data needs to be returned for Rainlab.Pages menu to work):

In YourModel the implementation might look like this (this code is simplified for this plugin purposes, more data needs to be returned for Rainlab.Pages menu to work):

To see your model SEO on the frontend, you will need to use the component SeoModel in your page:

The property pageType should be the same YourModel property $seoPageType

The property pageProperty tells the plugin in which page property can find your model. It's usually filled by a component on the onRun method:

If you already use some fields in your model for SEO purposes, you can map them listening to zmark.seo.mapSeoData event:

In YourModel, one possible implementation might look like this:

Extending your own models

A SEO tab with easier access to SEO data creation can be attached to your model. You need to implement the Seo Model Behavior in your model class:

This code will insert a new tab in your models for previewing, creating or editing the SEO data.


Sitemap generator

This plugin will generate a sitemap.xml file based on desired CMS pages and others. The generated sitemap follows Google guidelines for multi-lingual sitemaps.

Viewing the sitemap

Once this plugin the sitemap has been configured, it can be viewed by accessing the file relative to the website base path. For example, if the website is hosted at http://example.com it can be viewed by opening this URL:

http://example.com/sitemap.xml

You should add this url to your robots.txt file.

This sitemap will not render in browsers, this is a known issue. Unfortunately, the only known way to solve this issue makes the sitemap incompatible with Google Search Console. As a workaround, a sitemap-debug.xml is also generated. This sitemap renders ok in browsers and it can be viewed by opening this URL:

http://example.com/sitemap-debug.xml

THIS SITEMAP IS ONLY FOR DEBUG PURPOSES, DON'T SUBMIT THIS URL TO GOOGLE SEARCH CONSOLE.

Managing a sitemap definition

The sitemap is managed by selecting Sitemap from the Seo plugin menu. There is a single sitemap definition for each theme and it will be created automatically.

A sitemap definition can contain multiple items and each item has a number of properties. There are common properties for all item types, and some properties depend on the item type. The common item properties are Priority and Change frequency. The Priority defines the priority of this item relative to other items in the sitemap. The Change frequency defines how frequently the page is likely to change. Depending on the selected item type you might need to provide other properties of the item. The available properties are described below.

Reference

A drop-down list of objects the item should refer to. The list content depends on the item type. For the Static page item type the list displays all static pages defined in the system. For the Blog category item type the list displays a list of blog categories.

CMS Page

This drop-down is available for item types that require a special CMS page to refer to. For example, the Blog category item type requires a CMS page that hosts the blogPosts component. The CMS Page drop-down for this item type will only display pages that include this component.

Standard item types

The available item types depend on the installed plugins, but there are some basic item types that are supported out of the box.

URL

Items of this type are links to a specific fixed URL. That could be an URL of an or internal page. Items of this type don't have any other properties - just the title and URL.

CMS page

Items of this type refer to CMS pages. The page should be selected in the Reference drop-down list described below.

Custom item types

Other plugins can supply new item types. Some are supported out of the box:

Rainlab Pages plugin

This plugin supplies two new item types:

Static page

Items of this type refer to static pages. The static page should be selected in the Reference drop-down.

All static pages

Items of this type expand to create links to all static pages defined in the theme.

Rainlab Blog plugin

This plugin supplies four new item types:

Blog category

An item of this type represents a link to a specific blog category. The category should be selected in the Reference drop-down. This type also requires selecting a CMS page that outputs a blog category.

All blog categories

An item of this type expands into multiple items representing all blog existing categories. This type also requires selecting a CMS page.

Blog post

An item of this type represents a link to a specific blog post. The post should be selected in the Reference drop-down. This type also requires selecting a CMS page that outputs a blog post.

All blog posts

An item of this type expands into multiple items representing all blog existing posts. This type also requires selecting a CMS page.

Registering new sitemap definition item types

The Sitemap plugin shares the same events for registering item types as the Pages plugin. See the documentation provided by this plugin for more information.

When resolving an item, via the pages.menuitem.resolveItem event handler, each item should return an extra key in the array called mtime. This should be a Date object (see Carbon\Carbon) or a timestamp value compatible with PHP's date() function and represent the last time the link was modified.

Each item should also append all alternate language (including the default language) urls in the array called alternate_locale_urls.

Expected result format:

Example of how to do this in your own models (simplified):


All versions of seo-plugin with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0
composer/installers Version ~1.0
madeitbelgium/seo-analyzer Version ^0.7.3
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 zmark/seo-plugin contains the following files

Loading the files please wait ....