Force HTTP redirect to HTTPS

Problems with the Linux version of XAMPP, questions, comments, and anything related.

Force HTTP redirect to HTTPS

Postby scopa » 04. November 2014 14:26

I have a new install and am new to apache (XAMPP)

I have my site setup and can access it manually by entering https://mysite.com/folder but it does not force the redirect to SSL

I have tried entering beloe in https-xampp.conf but apache doesnt start "bad flag delimiter"

Code: Select all
# Redirect /<em><span style="color: red;">folder_name</span></em> folder to https
   RewriteCond %{HTTPS} !=on
   RewriteCond %{REQUEST_URI} <em><span style="color: red;">folder_name</span></em>
   RewriteRule ^(.*) https://%{SERVER_NAME}$1 [R,L]


I am confused on which file I need to edit since httpd.conf points to httpd-ssl.conf and httpd-xampp.conf in the httpd.conf file.

What should I be entering and where? If I have left out any information please let me know. Running on ubuntu 14.10 x64

Thank you,
scopa
 
Posts: 1
Joined: 04. November 2014 14:21
Operating System: ubuntu 14.10

Re: Force HTTP redirect to HTTPS

Postby Nobbie » 04. November 2014 16:24

scopa wrote: RewriteCond %{REQUEST_URI} <em><span style="color: red;">folder_name</span></em>


This is horrible nonsense (like mixing english and chinese), I think you first of all should learn about rewriting URLs.

Anyway, i dont get your question, what to do you want to redirect from http to https?
Nobbie
 
Posts: 13175
Joined: 09. March 2008 13:04


Return to XAMPP for Linux

Who is online

Users browsing this forum: No registered users and 116 guests