This update lets you remove URL bases under General Settings → Canonical. Choose which public hierarchical taxonomies to shorten, including categories, WooCommerce product categories and brands, and custom taxonomies. For example, /category/recipes/bread/ becomes /recipes/bread/. If the shorter URL is already taken, the SEO Bar tells you. We also fixed an edge case where database upgrades could discard legacy settings before migrations finished.
Detailed log
For everyone
- Added:
- Taxonomy base removal. Choose which public hierarchical taxonomies to shorten under General Settings → Canonical. The options are off by default and require pretty permalinks. See the guide to removing taxonomy URL bases.
- Shortened URLs preserve nested term paths and permalink prefixes. The original addresses still work. The shortened URL becomes the default canonical. When you change a term slug, the previews in term edit and Quick Edit follow the taxonomy’s setting.
- Feeds and pagination work with both permalink paths and the
feedandpagedquery arguments. WooCommerce catalog sorting works on shortened product category URLs. - Public pages, posts, and existing archives take precedence. Visitors who cannot view an unpublished page or post can still reach the shortened term URL. If two shortened term URLs conflict, the first taxonomy listed in the settings wins. TSF still generates shortened URLs for conflicting terms.
- When TSF detects a conflict, the term list and editor show a full-width red Term URL conflict warning, marked
!!!by default. The check recognizes custom term rewrites and the designated posts page. Term lists check the displayed rows in a batch. If a redirect is configured for the term, the tooltip explains that it remains active at the original URL. - If you restore a taxonomy base, use a redirect plugin or your host’s redirect tools to add permanent (301) redirects for shortened URLs that are now unused. For example, redirect
/recipes/bread/to/category/recipes/bread/. This redirect feature is already in the works for TSF’s next major update.
- Taxonomy base removal. Choose which public hierarchical taxonomies to shorten under General Settings → Canonical. The options are off by default and require pretty permalinks. See the guide to removing taxonomy URL bases.
- Improved:
- Settings migrations. On multisite, if a site switch is active, TSF now defers the upgrade or downgrade until the next eligible request to that site. When rolling back from a newer version to TSF 5.2.2, the database downgrade fills in missing defaults and prunes unknown top-level settings.
- Compatibility:
- Plugin: Multisite Language Switcher:
- On PHP 8.1 and later, category hreflang links follow the destination site’s category base setting, whether the current site keeps or removes its own. On PHP 8.0 and 7.4, links reuse the current site’s setting instead, which causes a 404 when a site that removes its base links to one that keeps it.
- Plugin: Polylang:
- Shortened term URLs retain their language when requested with a language query parameter.
- Plugin: WPML:
- Shortened term URLs preserve language directories and language query parameters, and work with WPML’s term-link cache.
- Plugin: Multisite Language Switcher:
- Fixed:
- Resolved an edge-case issue where database upgrades could discard legacy settings before migrations finished, overwrite source settings in a secondary language, or mark an upgrade complete before verifying the saved value.
- Resolved an edge-case issue where saving or resetting SEO settings during a pending database upgrade could fail silently instead of showing a retry message.
For translators
- Updated:
- The bundled POT file has been updated.
For developers
- PHP API notes:
- Added:
The_SEO_Framework\flag()reads or sets a named flag shared across functions for the current request. Omit the value or passnullto read. An unset flag returnsnull.The_SEO_Framework\Helper\Taxonomy::is_base_removal_enabled()(tsf()->taxonomy()->is_base_removal_enabled()) reads the per-taxonomy base-removal setting, defaulting to the current taxonomy.The_SEO_Framework\Helper\Taxonomy\Base_URL::get_taxonomies()(tsf()->taxonomy()->base_url()->get_taxonomies()) lists public hierarchical taxonomies with viewable rewrite URLs, sorted by taxonomy name.The_SEO_Framework\Helper\Taxonomy\Base_URL::supports_base_removal()(tsf()->taxonomy()->base_url()->supports_base_removal()) checks whether a registered taxonomy supports base removal. It accepts a taxonomy name or object.The_SEO_Framework\Helper\Taxonomy\Base_URL::should_remove_taxonomy_base()(tsf()->taxonomy()->base_url()->should_remove_taxonomy_base()) checks whether base removal applies to the named taxonomy under the current permalink structure and settings.The_SEO_Framework\Helper\Taxonomy\Base_URL::strip_taxonomy_base()(tsf()->taxonomy()->base_url()->strip_taxonomy_base()) removes the registered base from a taxonomy permalink structure while retaining its permalink front and root.The_SEO_Framework\Meta\URI\Utils::get_term_slug_path()(tsf()->uri()->utils()->get_term_slug_path()) gets the term’s slug path using its taxonomy rewrite hierarchy.- The term SEO Bar’s
urlconflictassessment checks shortened URL conflicts wherever the bar is generated. Theredirecttest continues to assess configured redirects only. The_SEO_Framework\Admin\SEOBar\Builder::has_blocking_item()($interpreter::has_blocking_item()) reports whether any registered SEO Bar assessment is marked as blocking.- SEO Bar builders passed to
the_seo_framework_prepare_seo_barandthe_seo_framework_seo_barexpose$builder::TYPE('single','term', or'user', defaulting tonull).
- Changed:
The_SEO_Framework\Data\Plugin::update_option()(tsf()->data()->plugin()->update_option()):- Now uses the same WordPress settings sanitization in admin, front-end, and REST requests after TSF initializes. This prepares settings writes for the planned Gutenberg sidebar integration.
- Now merges changes into defaults when the saved settings value is a non-array.
- Now refreshes settings and post type archive meta on WordPress’s post-write actions.
- Now returns false while a database upgrade is pending.
- TSF’s option-specific pre-update filter checks the site’s database version on each ordinary WordPress
update_option()call and returns the stored settings while an upgrade is pending. The_SEO_Framework\Data\Plugin\Setup::get_default_options()(tsf()->data()->plugin()->setup()->get_default_options()) addedremove_taxonomy_bases, disabled by default.The_SEO_Framework\Meta\URI::get_custom_canonical_url_from_query()(tsf()->uri()->get_custom_canonical_url_from_query()) andThe_SEO_Framework\Meta\URI::get_generated_url_from_query()(tsf()->uri()->get_generated_url_from_query()) now memoize after thewpaction.The_SEO_Framework\Meta\URI\Utils::get_url_permastruct()(tsf()->uri()->utils()->get_url_permastruct()) now accounts for taxonomy base removal when predicting term URLs.The_SEO_Framework\Helper\Query::get_the_real_id()(tsf()->query()->get_the_real_id()) now waits for thewpaction before caching the front-end ID.The_SEO_Framework\Helper\Query::get_the_front_page_id()(tsf()->query()->get_the_front_page_id()) now waits for thewpaction before caching the front-page ID on front-end requests.The_SEO_Framework\Helper\Query::is_static_front_page()(tsf()->query()->is_static_front_page()) now waits for thewpaction before caching the front-page ID on front-end requests.The_SEO_Framework\Helper\Query::is_sitemap()(tsf()->query()->is_sitemap()) now uses the sharedis_sitemap_queryflag.The_SEO_Framework\Helper\Query\Cache::memo()(tsf()->query()->cache()->memo()):- Now waits for the
wpaction before caching front-end queries. - Now skips serialization when no extra arguments are passed.
- Now waits for the
The_SEO_Framework\Helper\Query\Cache::can_cache_query()(tsf()->query()->cache()->can_cache_query()):- Now waits for the
wpaction before caching front-end queries. - Now omits the debug notice for early query reads.
- Now waits for the
The_SEO_Framework\Helper\Query\Utils::using_pretty_permalinks()(tsf()->query()->utils()->using_pretty_permalinks()) now caches per site.The_SEO_Framework\Helper\Query\Utils::query_supports_seo()(tsf()->query()->utils()->query_supports_seo()) now waits for thewpaction before caching front-end SEO support.The_SEO_Framework\Helper\Query\Utils::is_query_exploited()(tsf()->query()->utils()->is_query_exploited()) now waits for thewpaction before caching front-end query protection.
- Fixed:
The_SEO_Framework\Data\Plugin::get_options()(tsf()->data()->plugin()->get_options()) now falls back to defaults when WordPress returns a non-array settings value.The_SEO_Framework\Data\Plugin::flush_cache()(tsf()->data()->plugin()->flush_cache()):- Now refreshes the settings and post type archive caches after successful additions, updates, and deletions of the settings option.
- Now runs on admin, front-end, and REST requests.
The_SEO_Framework\Data\Plugin\Setup::reset_options()(tsf()->data()->plugin()->setup()->reset_options()):- Now refreshes post type archive meta when WordPress adds or updates the settings option.
- Now returns false while a database upgrade is pending.
- Settings sanitization preserves the stored option when given an empty or malformed payload, even if the stored value is malformed.
The_SEO_Framework\Admin\SEOBar\Builder::generate_bar()(tsf()->admin()->seobar()->generate_bar()) now uses the matching builder when generating post, term, and user SEO Bars in the same request.
- Added:
- Option notes:
- Added:
remove_taxonomy_basesmaps selected taxonomy names to1. Omit a taxonomy to deselect it. TSF settings sanitization discards unselected entries. The option defaults to an empty array and is registered as such for upgraded sites at database version5220.
- Added:
- Action notes:
- Changed:
the_seo_framework_upgradedandthe_seo_framework_downgradednow fire only after the settings and database version are verified.- On
the_seo_framework_prepare_seo_bar,$builder::$testsnow controls regular assessments. Each builder runs its blocking checks independently.
- Changed:
- Filter notes:
- Added:
the_seo_framework_get_term_home_urlfilters the home URL used to interpret stored term rewrite rules. It receives the stored home URL and the term URL being checked.the_seo_framework_term_route_contextfilters the query variables that qualify a shortened term request without claiming its path. Add their names as keys with a value oftrueto carry their request values over to the winning term query.
- Changed:
the_seo_framework_settings_update_sanitizersnow also runs for WordPress writes to TSF settings outside TSF’s default settings flow.
- Added: