WebFaction
Community site: login faq

I have Wordpress installation using working fine using https working fine for my site https://www.domain.com/

When a try http://www.domain.com/ I get Webfaction "Site not configured"

So I want to redirect http traffic to https

I added to bottom of .htaccess file in app root directory this code from documentation

RewriteEngine On
RewriteCond %{HTTP:X-Forwarded-SSL} !on
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]

It doesn't seem to do anything.

I verified this .htaccess file is for this Wordpress install (I deleted the file, then saved permalink settings to generate new file)

I'm at a loss to why the code isn't working. Any thoughts.

asked 12 May, 21:33

atticus's gravatar image

atticus
113
accept rate: 0%

edited 12 May, 22:53

seanf's gravatar image

seanf ♦♦
11.5k21233

Oh, No I did not. The wordpress install was originally a http site and I enabled encryption (https / SSL) on that existing site.

So I need to create another static site the the http site, which will only contain redirects to the https site.

FIXED! That solved it! Thanks!

1) Created a static http site for that same domain.

2) Added .htaccess file with redirect code to http static site root directory.

After that, everything worked!

(12 May, 22:22) atticus atticus's gravatar image

Thank you SethKinast! That was all I needed. Appreciate the help.

(12 May, 22:24) atticus atticus's gravatar image

Did you create a static app that uses HTTP? It is separate from your WordPress app using HTTPS.

permanent link

answered 12 May, 21:54

SethKinast's gravatar image

SethKinast
25929
accept rate: 54%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×229
×68
×2

question asked: 12 May, 21:33

question was seen: 111 times

last updated: 12 May, 22:54

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2016 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM