• Stars
    star
    267
  • Rank 152,727 (Top 4 %)
  • Language
    PHP
  • License
    MIT License
  • Created over 8 years ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

SEO utilities including a unique field type, sitemap & redirect manager

SEO for Craft CMS

SEO for Craft CMS

SEO for Craft does three things that will help your sites SEO, and does them really damn well:

  1. Optimisation Field Type - Helps your clients write better optimised copy, and manage other SEO meta.
  2. Sitemap - Generates an always up-to-date XML sitemap automatically, with controls for customisation.
  3. Redirects - Quickly and easily manage 301 & 302 redirects. Especially useful when migrating from an old site.

Click here for the Craft 2 version.

The Field Type

The SEO field type helps give users an idea of how their page will look in Google, and how their pages content scores when compared to a specific keyword.

The field type allows users to manage the meta of their page in one simple and easy to use input that has the added bonus of giving them an idea of how their page will show up in a Google search.

The field also contains a Focus Keyword input and Page Score. This is used to workout how relevant a keyword or phrase is to your entry and how well the page is likely to do in a search for that keyword.

The Page Score also contains a breakdown of your entries score, and tips on where it can be improved.

SEO for Craft CMS

SEO Social

SEO Advanced

The Sitemap

SEO for Craft boasts an extremely powerful, yet simple to use Sitemap manager. With automatic support for all your site’s sections and categories (with localisations taken into account), and the ability to easily add custom URLs (useful for public templates that aren’t content managed), keeping your sitemap up-to-date has never been easier.

With SEO for Craft’s sitemap manager you have complete control over what content you want to have appear on your sitemap as well as managing its change frequency and priority in your site.

SEO Sitemap

The Redirects

When moving from your old, awful site to your shiny new Craft one, you’ll want to make sure that all your old pages are redirected to their new counterparts. Redirects are easy to manage with SEO for Craft.

SEO for Crafts redirect manager lets you easily add 301 & 302 redirects, with full .htaccess style regex support!

Redirects support PCRE regex syntax. By default, all / and ? not inside parenthesis are escaped. To prevent any escaping include the opening and closing forward slashes and flags: /^blog$/i. All redirects are given the insensitive flag, unless overwritten.

Redirect Regex Example
To redirect from blog/2016/my-post to news/my-post you would add the following redirect:

URI: blog/([0-9]{4})/(.*) To: news/$2

SEO Redirects

Installation & Usage

Clone this repo into craft/plugins/seo.

Using Composer

Easy way

composer require ether/seo

Alternative way

  1. Append "ether/seo": "^3.1.0" to the require hash of composer.json
  2. composer update
  3. Install via CP in /admin/settings/plugins

Before using the SEO field type, you’ll need to ensure all the settings are correct. You can find the settings under the SEO plugin menu in the sidebar, or via the plugin menu.

Environment Setup

Ensure that your Production environment’s name is production (going with Craft’s convention). All other environments will get X-Robots-Tag: none, noimageindex headers added to every web response, to prevent search engines from indexing duplicate content.

Environment names are typically defined by an ENVIRONMENT environment variable.

Fieldtype Usage

Replace your title tag, and any other SEO related meta tags with {% hook "seo" %}. That's it!

This assumes that you will be creating a variable call seo in your templates that will return either the SEO field or a custom SEO object (see below). You can modify the output of this hook by setting your own SEO Meta Template in the SEO Settings. You can view the default template here.

Custom SEO Object

In some cases, you will not have access to an SEO field, but will want to set the page title, description, & socials. You can do this by creating a custom SEO object using the function below:

craft.seo.custom(
    'The Page Title',
    'The page description',
    null,

    // Social media - Any missing fields (excluding images) will be populated by the values above
    {
        twitter: { image: myImageField.first() },
        facebook: { title: '', description: '', image: myImageField.first() },
    }
)

alternatively pass an object as the first parameter. This will be used in place of an element.

craft.seo.custom(
    {
        title: 'The Page Title',
        someField: 'Hello world!',
    },
    'The page description'
)

All parameters are optional.

Upcoming Features

If you have a feature suggestion, leave an issue with the prefix [FR].


Copyright © 2016 Ether Creative [email protected]

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

More Repositories

1

react-native-shadow-generator

Because lazy
HTML
164
star
2

simplemap

A beautifully simple map field type for Craft CMS.
PHP
137
star
3

yii2-ip-ratelimiter

Allow guest clients to be rate limited, using their IP as the identifier
PHP
38
star
4

react-native-tips

Useful shit we've learnt using React Native
36
star
5

colormixer

A set of hex color manipulation Twig filters for Craft
PHP
26
star
6

splash

Quickly and easily get beautiful Unsplash images in Craft!
JavaScript
22
star
7

tags

A tag manager for Craft 3
PHP
22
star
8

out

A reporting / export CSV plugin for Craft CMS
PHP
19
star
9

bookings

An advanced booking and events management plugin for Craft CMS and Craft Commerce
PHP
16
star
10

logs

Quickly check your logs in the Craft 3 utilities section.
PHP
12
star
11

yii2-login-attempts-behavior

PHP
10
star
12

react-native-date-input

A simple React Native date input component that uses DatePickerAndroid and DatePickerIOS to select dates
JavaScript
9
star
13

atom

Adding enhanced modularity to Craft CMS Twig templating
PHP
8
star
14

yii2-app-api

Yii 2 RESTful API Template
PHP
8
star
15

sidebar-entrytypes

Easily switch between entry types in the entries section
PHP
7
star
16

web-payments

Web Payments for Craft Commerce
PHP
5
star
17

mailchimp-commerce

Mailchimp integration with Craft Commerce
PHP
5
star
18

markdown

A Markdown fieldtype for Craft CMS
JavaScript
4
star
19

react-native-form-auto-next

A simple React Native form component that automatically focuses the next TextInput on return
JavaScript
4
star
20

next-starter

TypeScript
3
star
21

purchase-patterns

Easily keep track of and show products customers bought together. Plus, sorting by individual and order sales.
PHP
3
star
22

TokenAuth

A JWT based authorisation / api plugin for Craft
PHP
3
star
23

status

A custom status fieldtype for Craft CMS
PHP
3
star
24

storefront

Easily integrate Shopify with Craft CMS!
PHP
3
star
25

react-native-starter

TypeScript
3
star
26

titch

Compresses images using the TinyPNG API
PHP
3
star
27

ether-ui-example

TypeScript
2
star
28

icecat

A reader for the icecat "api".
PHP
2
star
29

thumbro

Craft CMS image transformations powered by Thumbor
PHP
2
star
30

playbook

Our Playbook for making sure Ether operates smoothly.
2
star
31

cookieconsent

Craft Plugin for Cookie consent
2
star
32

nginx-cache

Smart static caching with Nginx
PHP
2
star
33

critical

A Critical CSS generator for Craft CMS
PHP
2
star
34

js-rrule

Lightweight and fast recurring dates library for JS (RFC 5545)
JavaScript
2
star
35

yii2-slack-error-logger

Send errors (5xx) to a slack channel
PHP
2
star
36

imager-thumbor

Thumbor transformer for Imager
PHP
1
star
37

docski

Static docs generator
JavaScript
1
star
38

formski

A form building plugin for Craft CMS
PHP
1
star
39

SEOKit

The ultimate SEO toolkit for Craft CMS
PHP
1
star
40

mux

Automatically generate Mux videos from Craft CMS assets
PHP
1
star
41

starkers

CSS
1
star
42

notes

A note taking fieldtype for Craft CMS
PHP
1
star
43

voucher

Purchasable Coupons & Gift Vouchers for Craft Commerce
PHP
1
star
44

ethercreative.github.io

HTML
1
star
45

Ether-Gallery

A gallery plugin for jQuery
JavaScript
1
star
46

BetterImages

A better way of generating images code side, for WordPress
PHP
1
star
47

telemetry-web

The web / server for Telemetry
JavaScript
1
star
48

cart-notices

Automatically show notices based off cart details
PHP
1
star
49

craft-b

Shared module for traditional Craft/Twig sites
PHP
1
star
50

whympr-grades

Whympr Grade Descriptions
HTML
1
star
51

docker-remote-proxy

Quick and easy docker nginx proxy with wildcard SSL using Traefik
Shell
1
star
52

commerce-paybear

PayBear.io integration with Craft Commerce
JavaScript
1
star
53

entry-preview

PHP
1
star
54

craft-vue

A helper module for building Craft CMS plugins with Vue components
PHP
1
star
55

Craft-Tips

A collections of useful tips and tricks for Craft CMS
1
star
56

telemetry

A helper for anonymous tracking of Craft CMS plugin usage
PHP
1
star
57

tasks-task

JavaScript
1
star
58

w8

Sort entries by category and weight
PHP
1
star
59

apie

PHP
1
star
60

confirmation-email

HTML
1
star
61

graphiql

JavaScript
1
star
62

checkout

A universal checkout flow for Craft Commerce
PHP
1
star
63

paseo

Easy to use SEO
PHP
1
star
64

yii2-graphql

Helpers and filters to make GraphQL a bit easier to set up.
PHP
1
star
65

utility-belt

A collection of things we use on every Craft CMS site
PHP
1
star
66

compound

A little sketch UI library used internally, but totally cool for others to use.
1
star
67

yii2-beenpwned-validator

PHP
1
star
68

po-request

HTML
1
star
69

docker-craft-php-fpm-alpine

Dockerfile
1
star
70

yii2-sendgrid

Simple SendGrid wrapper for sending only
PHP
1
star
71

yii2-sendgrid-unsubscribe

A Yii2 module to easily provide public unsubscribe urls with suppression group support.
PHP
1
star