old site uses index.aspx
or service-type.aspx
New site uses or
service-type
which is now wordpress
I tried many syntax posted on SO doesn’t seem to redirect at all.. Not sure what my mistake is.
htaccess file
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.aspx -f
RewriteRule ^(.*?)/?$ $1.aspx [L]
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
Have tried other SO posted solutions but always ends up on 404 for wordpress.
You would like to remove
.aspx
from old links. Have your .htaccess like this: