WordPress

How to create breadcrumbs from post categories
How to create breadcrumbs from post categories

As you probably know, WordPress is a very widespread CMS — and people try to use it just about everywhere. Working on some projects, you can’t help but wonder: why use it here? Wouldn’t it be simpler and more efficient to use something built on a PHP framework? But trends are what they are — WordPress is used where it’s needed, and often where it isn’t.

Today’s post is not about whether WordPress should or shouldn’t be used in certain projects. Instead, you’ll learn how to generate a term array or build breadcrumbs for a post. It doesn’t matter what post type you’re using — a regular post or a custom post type — or whether the taxonomy is built-in or custom.

read more...

How to enable caching of adsense ads from google in wp-rocket
How to enable caching of adsense ads from google in wp-rocket

WP Rocket is one of the most popular caching plugins for WordPress, offering a rich set of features and flexibility.

WP Rocket has the ability to combine and minify JavaScript and CSS, generating a separate file for each. Additionally, it collects all inline JS/CSS from the site's HTML code and adds it to the aggregated cached files. This is certainly convenient, but in some cases — especially when used alongside other plugins — it can lead to errors or improper behavior.

read more...

How to programmatically change the name and description of a site in Yoast SEO
How to programmatically change the name and description of a site in Yoast SEO

The Yoast SEO plugin for WordPress provides a solid set of hooks that allow you to flexibly manipulate data when building your own meta tags.

In this article, we’ll look at an example where you need to change the site’s title and meta-description for a specific page. The example is simple and is intended to demonstrate how the hooks work. The logic can be customized however you like. For instance, in one of my projects, I had to dynamically generate titles and descriptions depending on the selected region and the services provided. It was a services directory broken down by country, region, city, and category list.

read more...

How to Disable Pagination in Category and Tag Canonical Links in Yoast SEO
How to Disable Pagination in Category and Tag Canonical Links in Yoast SEO

There’s a great plugin called Yoast SEO by Yoast available in the WordPress repository. It includes a wide range of features that meet the needs of most beginner — and even advanced — SEO specialists.

However, this post is not about its feature set or advantages over other similar plugins. Instead, we’ll focus on pagination in canonical URLs for tags and categories.

read more...