Apache Server .htaccess rewrite with wildcard -


is possible create rewrite code includes wildcard?

for example request for:

 http://example.com/something1/something2/* 

would redirect to:

 http://example.com/newthing 

and

will matter in .htaccess file place rewrites?

this should work you:

rewriteengine on rewriterule ^something1/something2/(.*)$ /$1 [r=302,l] 

it should change http://example.com/something1/something2/test http://example.com/test

edit:

rewriteengine on rewriterule ^shirts/(.*)$ /clothing.html [r=301,l] 

Comments

Popular posts from this blog

java - Intellij Synchronizing output directories .. -

git - Initial Commit: "fatal: could not create leading directories of ..." -