Problems with .htaccess in Apache2 Debian

1

I have installed on my local server (xampp + wordpress) a page with wordpress where I have a file .htaccess , this file is located in: xampp\apps\wordpress\htdocs\Directorio\.htaccess along with all my files .php , here everything works correctly.

Now my problem is that my national server is mounted on Debian Apache2.x. In the I have the wordpress installed running perfectly in this direction /var/www/hosproma/ .

Inside that folder, pass my Directory folder with everything and everything works except the config that I have in .htaccess .

I searched on the internet how to configure the apache, I configured the module, I changed the file inside sities-viable. I do not really know what is missing. I'm going to put my file .htaccess to see if it's wrong.

.htaccess:

RewriteEngine on
RewriteRule ^modificar/(\w+)$ modificar.php?id=$1

I do not know if I should change something because I changed my folder or my system.

    
asked by Omar Sarmiento Rolo 21.04.2016 в 15:17
source

1 answer

0
  • Make sure you have the mod_rewrite enabled

  • In the Virtual Host of your web you must have the AllowOverride All directive:

    <VirtualHost *>
        #Todo lo que tengas +
       <Directory /var/www/hosproma/>
           AllowOverride All
       </Directory>
    </VirtualHost>
    
  • Restart the apache2 service

  • answered by 07.09.2016 / 11:34
    source