Skip to content

Instantly share code, notes, and snippets.

@excid3
Created June 19, 2012 03:55
Show Gist options
  • Select an option

  • Save excid3/2952221 to your computer and use it in GitHub Desktop.

Select an option

Save excid3/2952221 to your computer and use it in GitHub Desktop.
Force non SSL
class ApplicationController < ActionController::Base
before_filter do
if request.ssl? && Rails.env.production? && request.domain == "mobicontact.net"
redirect_to :protocol => 'http://', :status => :moved_permanently
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment