I was using this WordPress permalink string.
/%postname%-%post_id%.html
but now I want to change it to, and redirect all old url’s to new url’s
/%postname%.html
Sample old url is;
http://www.example.com/dead-trigger-2-hile-mod-apk-indir-1890.html
The new url will be;
http://www.example.com/dead-trigger-2-hile-mod-apk-indir.html
My htaccess file currently using default wordpress vars. How can redirect all my urls to new urls 301.
I tryed to use this, but its not working
RedirectMatch 301 ^/(.*)-([0-9]{4})$ http://www.example.com/$1
Try the following
By following code you will be able to achieve 301 redirect via .Htaccess :
Syntax :
Example :