A
A
Andrey Petrov2015-07-28 16:26:46
Apache HTTP Server
Andrey Petrov, 2015-07-28 16:26:46

How to paste a part of a URL using Mod Rewrite?

Hello!
I really need help writing a rule in .htaccess to redirect from one URL to its augmented version.
There is a site URL starting with: http://site.ru/special/further_url
It is necessary that users, when following any of its internal links, always receive: http://site.ru/special/index.php/further_url
Tried Lots of options, but none of them really fit.
Thanks in advance!

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
ShamblerR, 2015-08-05
@anndmill

RewriteCond %{REQUEST_URI} ^(.*)/special/(.*)$
RewriteRule ^(.*)$ %1/special/inde.x.php/%2 [R=301,L]

A
Alexander, 2015-07-29
@Mixxer

A specific line-rule (of course there are many other necessary rules)
Demo:
9b7a90d8fff24bc7850c6d876db20073.png

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question