1
I have a site with thousands of pages with no URL friendly, so I want to put this feature..
My site currently looks like this: https://www.meusite.com.br/? pag=videos I want him like this: https://www.meusite.com.br/videos
I followed this path and it works!
RewriteEngine On
RewriteRule ^([0-9A-Za-z]+)$ index.php?pag=$1
However, the thousands of pages still continue with the old link and I won’t be able to change manually, so I thought I’d redirect 301 via. htaccess, but I can’t understand regular expressions to unify the above friendly url + 301 redirect in the links below:
https://www.meusite.com.br/?pag=noticias
https://www.meusite.com.br/?pag=noticias-exibe&news=nova-noticia-aqui
I took a look at the article from Agency which is more or less what I need, however, when I mix the old links with the new ones, it gets something like this and every time I click on these old links, they add more parameters to the initial links...
https://www.meusite.com.br/videos?pag=noticias?pag=videos?pag=dicas