The Apache Haus Forum

Advanced search  

News:

Welcome to Apache Haus Distribution Forum

Pages: [1]   Go Down

Author Topic: [SOLVED] htaccess Issues  (Read 155 times)

gouletf

  • Newbie
  • *
  • Offline Offline
  • Posts: 3
[SOLVED] htaccess Issues
« on: April 03, 2018, 08:14:12 PM »

I have spent 5 days on this issue, my .htaccess file is not recognized by apache.
It is located in htdocs/build beside my index.html.
I have activated mod_rewrite, AllowOveride has been set to All. The file doesn't even throw a 500 error when i give it random text, it doesn't log. One the other hand the exact same httpd.conf and exact same react.js build and the same htaccess runs perfectly on my bosses computer. If I place the htaccess code (its redirect code for an SPA) into <Directory "${SRVROOT}/htdocs/build"> it runs with no fault.

I am running Windows 7, I have tested this on Apache Haus 2.4.33 now it's running on 2.4.12 (to verify if it was an issue with version 33)
« Last Edit: April 04, 2018, 10:27:28 PM by gouletf »
Logged

Gregg

  • Administrator
  • Member Elite
  • *****
  • Offline Offline
  • Posts: 828
Re: htaccess Issues
« Reply #1 on: April 04, 2018, 05:49:18 AM »

What is the difference between htdocs/build & ${SRVROOT}/htdocs/build? Kinda confusing.
Logged

gouletf

  • Newbie
  • *
  • Offline Offline
  • Posts: 3
Re: htaccess Issues
« Reply #2 on: April 04, 2018, 03:35:58 PM »

I just wrote the ${SRVROOT} as a valriable to hold the name of the ServerRoot thats all
Define SRVROOT "/Apache/Apache24"
ServerRoot "${SRVROOT}"
Logged

Gregg

  • Administrator
  • Member Elite
  • *****
  • Offline Offline
  • Posts: 828
Re: htaccess Issues
« Reply #3 on: April 04, 2018, 05:10:13 PM »

I get that but you say it doesn't work in htdocs/build but does in ${SRVROOT}/htdocs/build and as far as I know they are both == c:\Apache24\htdocs\build. Even so I pondered this most of the day yesterday and could only come up with a problem in the filename (like missing a 'c' or an 's') so Apache couldn't recognize it. I have never had a problem with .htaccess files and even though I try to limit their use, I'm still using them.
Logged

gouletf

  • Newbie
  • *
  • Offline Offline
  • Posts: 3
Re: htaccess Issues
« Reply #4 on: April 04, 2018, 10:26:53 PM »

Thank you for your help I have solved the issue, when the react project is built the .htaccess file gets a .txt extension added to it. and I had file extensions turned off.
Logged
Pages: [1]   Go Up
 

Sitemap 1 2 3 4 5 6 7 8 9 10 11 12 13