Htaccess url rewrite - remove .php remove www. convert?id=10 to /10?

RewriteCond %{HTTP_HOST} ^www\.(.*)$ NC RewriteRule ^(.*)\. Php$ %1/$1 R=301,L RewriteCond %{HTTP_HOST} ^www\.(.*)$ NC RewriteRule ^(.*)\. Php\?

Id=(0-9+)$ %1/$1/$2 R=301,L.

I went to site. Com/product/10 and I got an 404? Same with site.

Com/some/page or site. Com/this No redirects or url rewriting? – derblub Aug 6 at 11:30 @blub Your description (the question) and the URL you are trying to go (the comment above) are two COMPLETELY DIFFERENT things -- in your question you are asking to do opposite to site.

Com/product/10. Decide/re-phrase your question first. – LazyOne Aug 6 at 11:36.

I supose that you, previously have this mod_rewrite rule active: Users goes to site.com/product/12 and in the browser is showed this URL, and internaly, and only internaly, server serve site.com/product.php?id=12 Put the first RewriteCond and Rule this: RewriteCond %{ENV:REDIRECT_STATUS}!200 RewriteRule ^(\w+)\. Php\? Id=(\d*)$ /$1/$2 R=301 And add another to remove the .

Php when ends with . Php RewriteCond %{ENV:REDIRECT_STATUS}!200 RewriteRule ^(\w+)\. Php$ /$1 R=301.

Unfortunately this isn't working too - I'm getting redirected from page. Php to page, but it shows me a 404 When I go to site. Com/product.

Php? Id=10 it redirects me to */product? Id10 and a 404 again :/ am I missing something?

– derblub Aug 6 at 11:35.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions