instance method
protocol
Ruby on Rails 3.0.20
Since v3.0.20Signature
protocol()
Returns ‘https://’ if this is an SSL request and ‘http://’ otherwise.
Source
# File actionpack/lib/action_dispatch/http/url.rb, line 15
def protocol
ssl? ? 'https://' : 'http://'
end
Defined in actionpack/lib/action_dispatch/http/url.rb line 15
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActionDispatch::Http::URL