Kim
Kim

Reputation: 275

Wamp rewrites url automatically?

I am facing some issues with url rewrite on windows wamp. The problem is whenever i access below urls

http://localhost/test/index

or 

http://localhost/test/index.php

It loads the home page. The problem is that wamp automatically hides php extention from urls, even after disabling mod_rewrite module. I'm also not using .htaccess file. This is very strange behaviour, This is the first time i got this issue.

Softwares:
        - WAMPSERVER 64BIT - 3.1.4
        - PHP Version 7.2.10
        - Apache Version 2.4.35

httpd-vhosts.conf

# Virtual Hosts
<VirtualHost *:80>
  ServerName localhost
  ServerAlias localhost
  DocumentRoot "${INSTALL_DIR}/www"
  <Directory "${INSTALL_DIR}/www/">
    Options +Indexes +Includes +FollowSymLinks +MultiViews
    AllowOverride All
    #Require local
    Require all granted
  </Directory>
</VirtualHost>

Any solution to turn off this automatic rewrites, so that i can do it myself via htaccess file. Thanks in advance.

Upvotes: 1

Views: 138

Answers (1)

Kim
Kim

Reputation: 275

Finally solved the problem. The problem was with wamp 3 software, it uses +MultiViews directive by default.

To solve the problem just replace,

Options +Indexes +Includes +FollowSymLinks +MultiViews

with

Options +Indexes +Includes +FollowSymLinks -MultiViews

Hope it helps someone!

Upvotes: 2

Related Questions