Introduction

The PWF - WooCommerce Products Filter provides an amazing tool that handles SEO. The SEO tool is coming with a lot of benefits. Including:

  • A simple admin interface
  • Drag and drop form builder
  • Support pretty and clean URLs.

Imagine that, you can generate a large number of URLs on the fly without writing any code. As a result, you will get more visitors through search engines without extra effort.

For example, .../shop/product-catgory-%any%/brand-%any%/ This link can generate a lot of URLs depending on how many categories and brands you have.

Table of content

What are Seo Plugins compatible with our plugin?

The PWF plugin is compatible with popular SEO plugins. It works only when you already activate one of these plugins.

  • Yoast SEO.
  • Rank Math.
  • All in One SEO.
  • SEOPress, on-site SEO.
  • SEO Plugin by Squirrly SEO.

Do you need us to add compatibility to other SEO plugins? So, contact us.

Plugin Meta Title Meta description Canonical URL Next & Prev Link Breadcrumbs
Yoast SEO Yes Yes Yes Yes Yes
Rank Math Yes Yes Yes Yes Yes
All in One SEO Yes Yes Yes Yes Yes
SEOPress Yes Yes Yes Yes Contact us
Squirrly SEO Yes Yes Yes No No

What front-end changes are being made by our SEO tool?

  • Changes that make in the HTML head tag.
    • Meta title.
    • Meta Description.
    • Previous and next links.
    • Social links.
    • Canonical url.
  • Other changes
    • H1 Title.(Sometimes, require to add some code)
    • Breadcrumbs.
    • Short description.

How to add a new SEO rule?

  • click the button + Add New SEO Rules To The Page.
  • Select the page that you want to add new rewrite rules at the end of its URL.
    • when you set that option to product archive. The URL may look like this: example.com/shop/
    • By adding new rewrite rules for SEO.The URL may look like this: example.com/shop/product-category-mobile/brand-apple/
    • The page that you chose in the previous step. It must have a related filter to it.
      For example,
      • Edit the filter settings. Then, clicking the data base query tab. set the option page to product archive.
      • Now, in the SEO rule, you set the option page to one of these choices:
        • Product Archive.
        • ALl product categories and custom category.
        • ALL tags and custom tag.
        • All taxonomies related to the post type product.
  • Click the button to add a new SEO rule and start fill fields with data.

How to add the search filter item to SEO URL?

  • Don't forget to replace the text "search_text" with the term you need to search for.
  • For the search term that contains two or more words, you need to separate them by space. For examle, android phone.

How to add a price and a Range slider filter item to an SEO URL?

There are two variables "min_value" and "max_value". Should replace with your own value.. For example:

  • Before edit, price-%min_value-to-max_value%/
  • After edit, price-%2-to-99%/

How to disblay breadcumbs on the front-end?

The theme must display breadcrumbs by using the SEO plugin function. If the SEO plugin supports this feature.

How to display the SEO short description on the front end?

The short description is different than the meta description. the meta description displays in the HTML <head> tag.

  • The shortcode [pwf_filter_seo_short_description] displays the SEO short description on the page.
  • Also, you cam use the widget "PWF: SEO SHORT DESCRIPTION" to display the SEO shortcode description..
<?php
add_action( 'woocommerce_before_main_content', 'seo_short_code_description', 5 );
function seo_short_code_description() {
    echo do_shortcode('[pwf_filter_seo_short_description]');
}
?>

How to Display the H1 title on the front end?

Sometimes the plugin tries to change the H1 title but this generates issues. or the theme uses its custom code to display the H1 page title.

If the theme using the default woocomerce function to display title the pwf plugin can change the H1 page title.

When our plugin can change H1 page title?

The PWF plugin can change the H1 title when the theme display H1 page title on these pages Archive, category, tag, and taxonomy. using these functions:

  • get_the_archive_title()
  • single_cat_title()
  • single_tag_title()
  • single_term_title()

How to fix the H1 Page title

You can use the shortcode [pwf_filter_seo_h1_title] to display the H1 seo title. The shortcode return empty string for pages don't have a custom SEO H1 title.

<?php
$orginal_title = "The current Page H1 Title";
$seo_h1_title  = do_shortcode('[pwf_filter_seo_h1_title]');
if ( empty( $seo_h1_title ) ) {
   return $orginal_title;
} else {
    return $seo_h1_title;
}

Try to use the WordPress filter "wp_title". Sometimes display error message.

PHP Fatal error: Uncaught Error: Xdebug has detected a possible infinite loop, and aborted your script with a stack depth of '100' frames in /srv/www/woodemo/public_html/wp-includes/option.php:78 .....

The WPML Plugin With the SEO tool.

  • Change the site Language to the language that you need to display an SEO rule.
  • Click the button "Add New SEO Rules To The Page".
  • Select the Page.
  • Select The language from the dropdown menu.
  • Click the button to add a new SEO rule and start fill fields with data.

API hooks for the SEO tool

Filter Name Default Value Description
pwf_seo_display_page_number_in_meta_title True Display/Hie page number in Meta Title.
pwf_seo_page_number_position_in_meta_title before_site_name Display page number before site name in Meta title. "at_end" to add it at the end.
pwf_seo_page_number_separator_in_meta_title | Change the separator for page number.
pwf_seo_enable_to_change_h1_title True Display|Hide Seo H1 title.
pwf_seo_h1_change_woocommerce_page_title True Display|Hide The SEO H1 title. When the theme display the page title using the function WooCommerce function woocommerce_page_title().
pwf_seo_h1_change_archive_title True Display|Hide The SEO H1 title. When the theme display the page title using the function get_the_archive_title().
pwf_seo_h1_change_term_title True Display|Hide The SEO H1 title. When the theme display the page title using these functions single_cat_title(), single_tag_title(), single_term_title().
pwf_seo_h1_change_the_title False Display|Hide The SEO H1 title. When the theme display the page title using the function wp_title(). Enable this filter may be breaking your site down.

Examples

<?php
// Hide page number
add_filter( 'pwf_seo_display_page_number_in_meta_title', 'pwf_seo_display_page_number_in_meta_title', 10, 1 );
function pwf_seo_display_page_number_in_meta_title( $enable ) {
    return false;
}

// Change page number position in meta title
add_filter( 'pwf_seo_page_number_position_in_meta_title', 'pwf_seo_page_number_position_in_meta_title', 10, 1 );
function pwf_seo_page_number_position_in_meta_title( $position ) {
    return 'at_end'; // Display at the end of title.
}

// Change separator that is using by page number
add_filter( 'pwf_seo_page_number_separator_in_meta_title', 'pwf_seo_page_number_separator_in_meta_title', 10, 1 );
function pwf_seo_page_number_separator_in_meta_title( $separator ) {
    return '-';
}

// Display the SEO H1 title
// For pages that are using the function wp_title()
// Important: Enable this filter may be breaking your site down
add_filter( 'pwf_seo_h1_change_the_title', 'pwf_seo_h1_change_the_title', 10, 1 );
function pwf_seo_h1_change_the_title( $enable ) {
    return true;
}

PWF Woocommerce Product Filters