Answer the question
In order to leave comments, you need to log in
How to find out why RewriteRule is not working?
Hello.
Faced apparently with a banal situation, however itself I can not solve it. You need to rewrite from this URL:
http://domain.tld/index.php?w=650&h=content&i=madam/rdo_map_nazar_1_sm.jpg
http://domain.tld/650/content/madam/rdo_map_nazar_1_sm.jpg
RewriteEngine On
RewriteRule ^([^/]*)/([^/]*)/([^/]*)$ /index.php?w=$1&h=$2&i=$3 [L]
<Directory /home/mo45/www>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
<VirtualHost *:80>
ServerAdmin [email protected]
ServerName domain.tld
DocumentRoot /home/mo45/www/rockstar/weazel
<Directory "/home/mo45/www/rockstar/weazel/">
Options +FollowSymLinks -MultiViews
RewriteEngine On
AllowOverride ALL
Allow from all
</Directory>
LogLevel alert rewrite:trace3
ErrorLog /home/mo45/www/rockstar/log/error.log
CustomLog /home/mo45/www/rockstar/log/access.log combined
</VirtualHost>
[Tue Dec 10 14:20:08.457690 2019] [rewrite:trace3] [pid 3897] mod_rewrite.c(482): [client 141.101.104.182:60012] 141.101.104.182 - - [domain.tld/sid#7f3bd4704a30][rid#7f3bcb27f0a0/initial] [perdir /home/mo45/www/rockstar/weazel/] add path info postfix: /home/mo45/www/rockstar/weazel/650 -> /home/mo45/www/rockstar/weazel/650/content/madam/rdo_map_nazar_1_sm.jpg
[Tue Dec 10 14:20:08.457929 2019] [rewrite:trace3] [pid 3897] mod_rewrite.c(482): [client 141.101.104.182:60012] 141.101.104.182 - - [domain.tld/sid#7f3bd4704a30][rid#7f3bcb27f0a0/initial] [perdir /home/mo45/www/rockstar/weazel/] strip per-dir prefix: /home/mo45/www/rockstar/weazel/650/content/madam/rdo_map_nazar_1_sm.jpg -> 650/content/madam/rdo_map_nazar_1_sm.jpg
[Tue Dec 10 14:20:08.458039 2019] [rewrite:trace3] [pid 3897] mod_rewrite.c(482): [client 141.101.104.182:60012] 141.101.104.182 - - [domain.tld/sid#7f3bd4704a30][rid#7f3bcb27f0a0/initial] [perdir /home/mo45/www/rockstar/weazel/] applying pattern '^([^/]*)/([^/]*)/([^/]*)$' to uri '650/content/madam/rdo_map_nazar_1_sm.jpg'
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question