Remove trailing /feed from permalinks that use a .html suffix

You can achieve this by adding the code to .htaccess file of your apache server. RewriteEngine On RewriteCond %{REQUEST_URI} ^/([0-9]{4})/([0-9]{2})/([^/]+)\.html/feed/?$ [NC] RewriteRule ^ /%1/%2/%3.html [R=301,L] The given code will helps you in set up a redirect so that any request to a post URL with /feed appended will be redirected to the original post URL … Read more

How to search WordPress for content specifically in title?

To specifically exclude posts with “2024” in their titles using a code snippet, you can add this to your theme’s functions.php file: function exclude_title_posts( $query ) { if ( $query->is_search && !is_admin() ) { $query->set(‘post_title_not_like’, ‘2024’); } } function modify_search_where( $where, $query ) { global $wpdb; if ( $title_not_like = $query->get( ‘post_title_not_like’ ) ) { … Read more

tech