Quantcast
Channel: Docs - AIOSEO
Viewing all 396 articles
Browse latest View live

Advanced Custom Fields integration with Title Format Fields

$
0
0

All in One SEO Pack integrates with the Advanced Custom Fields plugin so that you can use custom fields in your SEO titles and descriptions.

To integrate these, all you have to do is enter the following string into the Title Format fields under All in One SEO > General Settings > Title Settings:

%cf_fieldname%

Make sure you replace fieldname with the name of your custom field.


Filter to Disable All in One SEO Pack

$
0
0

If you would like to disable All in One SEO Pack on certain parts of your site, you can do so with the aiosp_disable API filter hook.

This will disable All in One SEO Pack’s document title, meta description, meta keywords, Opengraph meta, and anything else added to the head section.

Returning false based on whatever conditions disables AIOSEOP for those conditions.

add_filter( 'aiosp_disable', 'disable_aioseop', 10, 1 );

function disable_aioseop( $disable ){
    // Add logic here to detect certain post IDs, post types, etc.
    return true;
}

Installing All in One SEO Pack Pro

$
0
0

This video shows you how to install All in One SEO Pack Pro.

Setting up HTTPS SSL

$
0
0

Google announced back in August 2014 that they would start using HTTPS as a ranking signal.  Now more than ever, it’s important to use HTTPS to secure your site as well as improve your SEO.

Implementing HTTPS on a new site can be done by going to Settings > General and setting the URLs in the WordPress Address and Site Address fields to https://.  This should only be done on a new site.

If you are implementing HTTPS on an existing site then you will need to add the following code to your .htaccess file in the web root directory of your server:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://yoursite.com/$1 [R,L]
</IfModule>

Make sure you replace yoursite.com with your domain name.

If you are running NGINX then you would us this code:

server {
listen 80;
server_name yoursite.com www.yoursite.com;
return 301 https://yoursite.com$request_uri;
}

If you want to use HTTPS to secure your WordPress admin area then add the following line to your wp-config.php file in the web root directory of your server:

define('FORCE_SSL_ADMIN', true);

Place this line before the that says “That’s all, stop editing!”

You’ll need an SSL certificate installed on your server so contact your hosting company for that or consider switching to a hosting company that has signed up for Let’s Encrypt.

Finally, test each page on your site to make sure it’s fully secure.  You can use the Developer Tools in Chrome or a site such as Why No Padlock.

Filter to change canonical URL protocol

$
0
0

To change the protocol used for canonical URLs output by All in One SEO Pack, use the following code (return either http or https):

add_filter('aioseop_canonical_protocol', 'change_canonical_url_protocol');

function change_canonical_url_protocol(){
 return 'http';
}

Disable SEO in admin bar

$
0
0

All in One SEO Pack automatically displays SEO information in your admin bar. If for some reason you’d like to disable this functionality, you can do so with our filter hook, aioseo_show_in_admin_bar.

add_filter( 'aioseo_show_in_admin_bar', '__return_false' );

Remove All in One SEO Pack from top of menu

$
0
0

All in One SEO Pack automatically displays near the top of the menu in your WordPress dashboard. If for some reason you’d like to disable this functionality, you can do so with our filter hook, aioseo_custom_menu_order.

add_filter( 'aioseo_custom_menu_order', '__return_false' );

Filter SEO columns from edit post screen

$
0
0

If you would like to remove the SEO Title/Description columns from the edit post screen, you can do so by adding the following code to your functions.php

add_action( 'admin_head','remove_aiocolumns' );
function remove_aiocolumns(){
	remove_filter('manage_posts_columns','aioseop_mrt_pcolumns');
	remove_filter('manage_pages_columns','aioseop_mrt_pcolumns');
	remove_filter('manage_media_columns','aioseop_mrt_pcolumns');
}

Remove SEO News Dashboard Widget

$
0
0

If you’d like to remove the SEO News widget from the Dashboard of all administrators, use the following code in your functions.php:

add_filter( 'aioseo_show_seo_news', '__return_false' );

Advanced Custom Fields integration with Title Format Fields

$
0
0

All in One SEO Pack integrates with the Advanced Custom Fields plugin so that you can use custom fields in your SEO titles and descriptions.

To integrate these, all you have to do is enter the following string into the Title Format fields under All in One SEO > General Settings > Title Settings:

%cf_fieldname%

Make sure you replace fieldname with the name of your custom field.

Filter to Disable All in One SEO Pack

$
0
0

If you would like to disable All in One SEO Pack on certain parts of your site, you can do so with the aiosp_disable API filter hook.

This will disable All in One SEO Pack’s document title, meta description, meta keywords, Opengraph meta, and anything else added to the head section.

Returning false based on whatever conditions disables AIOSEOP for those conditions.

add_filter( 'aiosp_disable', 'disable_aioseop', 10, 1 );

function disable_aioseop( $disable ){
    // Add logic here to detect certain post IDs, post types, etc.
    return true;
}

Installing All in One SEO Pack Pro

$
0
0

This video shows you how to install All in One SEO Pack Pro.

Setting up HTTPS SSL

$
0
0

Google announced back in August 2014 that they would start using HTTPS as a ranking signal.  Now more than ever, it’s important to use HTTPS to secure your site as well as improve your SEO.

Implementing HTTPS on a new site can be done by going to Settings > General and setting the URLs in the WordPress Address and Site Address fields to https://.  This should only be done on a new site.

If you are implementing HTTPS on an existing site then you will need to add the following code to your .htaccess file in the web root directory of your server:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://yoursite.com/$1 [R,L]
</IfModule>

Make sure you replace yoursite.com with your domain name.

If you are running NGINX then you would us this code:

server {
listen 80;
server_name yoursite.com www.yoursite.com;
return 301 https://yoursite.com$request_uri;
}

If you want to use HTTPS to secure your WordPress admin area then add the following line to your wp-config.php file in the web root directory of your server:

define('FORCE_SSL_ADMIN', true);

Place this line before the that says “That’s all, stop editing!”

You’ll need an SSL certificate installed on your server so contact your hosting company for that or consider switching to a hosting company that has signed up for Let’s Encrypt.

Finally, test each page on your site to make sure it’s fully secure.  You can use the Developer Tools in Chrome or a site such as Why No Padlock.

Filter to change canonical URL protocol

$
0
0

To change the protocol used for canonical URLs output by All in One SEO Pack, use the following code (return either http or https):

add_filter('aioseop_canonical_protocol', 'change_canonical_url_protocol');

function change_canonical_url_protocol(){
 return 'http';
}

Filter XML Sitemap Data

$
0
0

Filtering the XML Sitemap Data for All in One SEO Pack can be done with the aiosp_sitemap_data hook.

This hook can accept four arguments; $sitemap_data, $type, $page, and $options.

$sitemap_data is an array of all URLs in your sitemap and accompanying data.
$type is the type of sitemap, usually root if you don’t have any additional sitemaps like a video sitemap
$page Starting at 0, this is the current page of a paged sitemap (0 if not paged)
$options This is an array of the sitemap options set.


What is a dynamically generated sitemap and why is it better to use?

$
0
0

Be default, All in One SEO Pack has always dynamically generated the XML Sitemap rather than output the XML Sitemap to a file on the web server.

A dynamically generated file is very common when working with a Content Management System and every page of content that WordPress outputs is dynamically generated from content in the WordPress database.  This is inherently better than creating static web page files like web developers used to 20 years ago.

There are four reasons why we do this, these are:

  1. The dynamically generated XML Sitemap is created every time it is requested.  This means it’s always up to date and accurately reflects the state of your site at that moment in time.
  2. A dynamically generated file is usually faster to access than a static file.  Search engines care about how long it takes to access your XML Sitemap so using a dynamically generated file is better for this reason.
  3. A static file can be overwritten, become corrupt or inaccessible due to server permissions issues.  A dynamic files cannot be overwritten, become corrupt of be inaccessible due to server permissions.
  4. Writing to a static file is a complicated process, it requires a lot of code to accommodate different server configurations and can be prone to bugs and conflicts.  Generating a dynamic file is a natural part of how WordPress works so is more reliable.

If you want to check whether you are using a dynamic XML Sitemap or a static XML Sitemap, go to All in One SEO > XML Sitemap > Dynamically Generate Sitemap.  If this is checked then you have a dynamic XML Sitemap.  If it is not, then you have static file and should consider changing this option to take advantage of the benefits of a dynamic XML Sitemap.

Why does the character counter for SEO titles show a different count?

$
0
0

The character counter shows the total number of characters for your title tag including the Site Title which is automatically appended to your title by All in One SEO Pack.

We append the Site Title in order to comply with Google’s Quality Guidelines for Titles and Descriptions which states that titles should be branded.  Specifically, they state “consider including just your site name at the beginning or end of each page title, separated from the rest of the title with a delimiter such as a hyphen, colon, or pipe”.  All in One SEO Pack does this for you and you can control this in the Title Format fields under All in One SEO > General Settings > Title Settings.

Therefore, if you have a Site Title that is 17 characters long including the pipe and spaces, then the character count for your SEO Titles will always start at 17 characters.  For example, the SEO Title below is 21 characters long, 4 characters for my title (FAQs), 17 characters for the Site Title, pipe and spaces (| Semper Plugins):

FAQs | Semper Plugins

FAQs = 4 characters

| Semper Plugins = 17 characters

Can I remove the date from Google search results?

$
0
0

The answer is no, you cannot ask or tell Google to remove the date from search results.  Whilst you can remove the date from your WordPress content, this does not mean it will have any effect on Google.

The official answer from Matt Cutts at Google can be found here –

Why doesn’t the title and description I set appear in search results?

$
0
0

When search engines like Google crawl your website, they do two things:

  1. They index the content (text and images) on the page;
  2. They check the source code of the page for meta data.

The meta data in the source code of a page includes the title tag and the meta description.  These are the SEO tags you can set in All in One SEO Pack for every page/post on your site.  As an example, below is the title tag and meta description for this FAQ as seen in the source code:

<title>Why doesn't the title and description I set appear in search results? | Semper Plugins</title>
<meta name="description" itemprop="description" content="The most frequently asked question in SEO is why doesn't Google display the title and description I set. This FAQ addresses that question." />

Google has answered this question many times.  The official answer is that Google takes into account the title tag and meta description as well as the content on your page as well as information from other sources.

When someone performs a search and Google returns results, they decide on what to display as the title and description (they call this the snippet).  They will choose what to display.  This may include either the title tag or meta description you provided, or it may not.  It’s entirely their choice and it is an automated process that runs each time a search is performed. Their decision is partly based on the search itself and the content of the page. If Google feels that it can generate a better title and/or description than the one you’ve provided, they’ll do so. Sometimes they do a great job with this, other times they don’t.

SEO is all about influencing search engines.  You cannot force a search engine to do what you want, and you cannot force search engines to use the meta data you provide.  All you can do is influence them by setting good titles and descriptions that meet the quality guidelines specified by companies such as Google.

Always adhere to the quality guidelines specified by the search engines, including staying within the maximum number of characters allowed, and making sure every SEO title and description is unique (no duplicates are allowed).

There is a video from Matt Cutts of Google explaining why they don’t always use your Meta Description here – https://www.youtube.com/watch?v=fpbpfjzEBAM

As a follow-up question, we get asked why you should set a custom SEO title and description on every page/post if search engines aren’t going to use them.

The answer is that this process is part of SEO, in fact it is a fundamental part of SEO.  Search engines expect you to do this, and if you care about SEO then you must set good SEO titles and descriptions on every page/post.  If you don’t then you’re not correctly optimizing your site for search engines.

For further reading, check out the following links:

  1. Quality Guidelines for SEO Titles and Descriptions
  2. Checking Index Status in Google Search Results
  3. Google’s official documentation here – https://support.google.com/webmasters/answer/35624?hl=en

Remove Canonical URL on a Page

$
0
0

If you need to disable All in One SEO Pack’s canonical URL functionality on a particular page, you can use the aioseop_canonical_url filter hook.

This filter hook accepts one parameter, which is the original URL. Use some sort of logic to determine the conditions, then you can either return a different URL, or simply return false to remove the canonical URL under those conditions.


add_filter('aioseop_canonical_url','change_canonical_url', 10, 1);

function change_canonical_url( $url ){

// Use whatever logic you like here. In this example, we’re returning a different canonical URL for post ID=2.

global $post;
if( $post->ID === 2){
return ‘http://canonicalurl.com’; // Return canonical URL for post #2.
}
return $url;
}

add_filter(‘aioseop_canonical_url’,’remove_canonical_url’, 10, 1);

function change_canonical_url( $url ){

// Use whatever logic you like here. In this example, we’re removing the canonical URL for post ID=2.

global $post;
if( $post->ID === 2){
return false; // Remove the canonical URL for post #2.
}
return $url;

}

Viewing all 396 articles
Browse latest View live