To add a page number regardless to any plugin … use filters. Do not change the plugin file. You cannot run updates other wise.
Example:
<?php # -*- coding: utf-8 -*-
/**
* Plugin Name: T5 Add page number to title
* Description: Adds <code> | Page $number</code> to the page title.
* License: MIT
* License URI: http://www.opensource.org/licenses/mit-license.php
*/
if ( ! function_exists( 't5_add_page_number' ) )
{
function t5_add_page_number( $s )
{
global $page;
$paged = get_query_var( 'paged' ) ? get_query_var( 'paged' ) : 1;
! empty ( $page ) && 1 < $page && $paged = $page;
$paged > 1 && $s .= ' | ' . sprintf( __( 'Page: %s' ), $paged );
return $s;
}
add_filter( 'wp_title', 't5_add_page_number', 100, 1 );
add_filter( 'wpseo_metadesc', 't5_add_page_number', 100, 1 );
}
Related Posts:
- Display Yoast WordPress SEO title in archive template
- How to add a page to the Yoast breadcrumbs
- How to print meta description to posts? [closed]
- Removing “Noindex, follow” from pages [closed]
- Why do I get a 404 for my sitemap index after installing Yoast? [closed]
- Change content language for one page
- Add Page number to Meta Description in WordPress SEO by Yoast [closed]
- Manipulating wp_head content
- Yoast’s WordPress SEO plugin is not showing the correct snippet [closed]
- XML Sitemap : broken XML file [closed]
- make the url unlimited
- Query Post Based of Yoast Primary Category Class
- Wrong Canonical url link
- When does the Yoast SEO filter hook wpseo_sitemap_urlimages fire?
- How to parse Yoast SEO Snippet Variables
- Post content blank after disabling Yoast SEO
- With the Yoast SEO plugin, is it possible to make the meta description a required form field?
- WP-RestAPI and xml sitemap
- help to write a custom php script to settingup yoast priority to pages or posts
- Yoast Seo Plugin – Set no-index to a post automatically when a post is set to sticky [closed]
- Yoast SEO Plugin: Double Title isse [closed]
- Yoast SEO creates sitemaps with a dash ‘-‘ but I can’t get Bing to accept them [closed]
- Edit title-tag in wp_head with yoast seo
- Way to change the Yoast Schema depending on post type? [closed]
- Change base URL of Yoast Sitemap [closed]
- Variable focus word YOAST
- How can I add a second Open Graph image to a site using Yoast? [closed]
- How to call Yoast Seo Tags without needing to call the whole wp_head?
- My WordPress website has 2 header [closed]
- Add content before Yoast description
- Twenty Eleven Theme – SEO Yoast duplicate site titles
- Blog home page has canonical link that is incorrect. Do not see where to change this
- How to Modify Breadcrumb Page Names for Specific Pages? [closed]
- P3 Profiler and Yoast SEO plugin
- WordPress site running on Yoast not being indexed into Google News [closed]
- How to use the Yoast SEO wpseo_canonical filter to set a canonical URL for /, /au/ & /uk/ sites in a MU environment
- Yoast Metadata API to adjust/override the meta description
- Prevent Yoast from removing the canonical tag if robots meta tag is set to noindex [closed]
- Fixing link rel=”next” in Yoast SEO for paginated links
- how to disable Yoast SEO schema from homepage only?
- WPML and Yoast SEO setup on a wordpress site is not working properly
- Remove canonical link element from noindex pages
- What could be causing the category to be appearing as the post title in the title tag?
- Changing Post Sitemap Frequency to Hourly [closed]
- Turn off auto 301 on archive pages? [closed]
- Yoast: do I still need to manually insert meta tags in my theme or will Yoast do this for me? [closed]
- Hard-code SEO Title defaults across all sites on a multisite
- WordPress site using Yoast SEO being blocked from indexing by robots.txt
- SEO Yoast Menu Not working
- Wrong Open Graph image is shown (og:image) using yoast
- An inactive plugin causes an HTTP 404 issue on a translated post – WPML
- Set default image for twitter cards with Yoast?
- Overwriting yoast’s og:meta output?
- yoast seo plugin – remove bulk title and description editor menu from non-admins [closed]
- Yoast SEO makes repeated INSERT queries loading any page
- how to add urls dynamically into the sitemap
- yoast sitemap xml
- Change Paginated Blog Canonicals
- Preview Problem Yoast SEO
- My wordpress website showing 2 titles in source code how can i fix this issue
- Separate Sitemaps for Each Language with Polylang and Yoast SEO
- How to display Yoast SEO meta description in archive template for each post instead of the_excerpt()? [closed]
- Allowing Yoast SEO plugin to track me
- Add a meta description to home page?
- Exclude custom post_type in sitemap generation?
- remove rel=next on home page but not others
- How do I get WordPress URL rewrites into Sitemap?
- Can I change the contents of a description meta tag generated by Yoast?
- One of my plugins broke when I tried to update it, how do I safely uninstall it?
- robots.txt Not Updating
- Yoast SEO: title tags are repeating my website name and slogan [closed]
- Regex expression for redirecting image URLs to another folder
- Where does the Yoast SEO plugin set the Open Graph metadata?
- Remove YoastSEO meta description from output/source [closed]
- the_content filter together with require_once returns 1 instead of the content of the included file
- Where does Yoast SEO plugin sets the site/page title?
- Yoast SEO breaking media upload
- Can’t print Yoast meta description into page template (syntax error, unexpected ‘.’) [closed]
- Help in using SEO Plugins: SEO Ultimate And Yoast SEO Plugin
- How-to: This block can only be used once
- Programmatically add Yoast meta description after post save
- How do I change the element using a custom function?
- How to see more WordPress images when posting to Facebook
- Genesis / custom template page / setting the page title and meta desc
- Yoast SEO plugin – Sitemap links greyed out & page priority
- Add parameters to Yoast SEO plugin schema in functions.php [closed]
- WordPress: Export/Import Yoast meta title & description to custom taxonomy
- Post Thumbnail missing when using webp format while sharing
- Link custom post type to parent page and show in slug / breadcrumb
- Does anyone know why my SEO and title become one?
- SEO Site Title appearing in google search despite not being added
- Divi Blog Module Plugin and YOAST SEO “Primary Category”
- Reorder title tag and description tag with wpseo_title and wpseo_metadesc
- How can I remove an unwanted character from the main page’s title?
- Category Name and Slug field need to be the same otherwise it breaks category pages
- how to make yoast seo read text from custom fields in custom post type
- Yoasts plugin sitemap not detecting correct category URL format
- Remove datePublished and dateModified from Yoast Schema output on WordPress website
- How to create archive child pages with good Yoast SEO meta?
- How can I do automatic redirects to canonical URLs as defined by Yoast SEO?