Module: Integral::MailHelper

Defined in:
app/helpers/integral/mail_helper.rb

Overview

Mail helper

Instance Method Summary collapse

Instance Method Details

#titleString

Returns html tag containing title. Could override this to instead render an image.

Returns:

  • (String)

    html tag containing title. Could override this to instead render an image.



12
13
14
# File 'app/helpers/integral/mail_helper.rb', line 12

def title
   :h1, Integral::Settings.website_title
end

#website_urlString

Returns <a> tag containing URL of website and hostname as label.

Returns:

  • (String)

    <a> tag containing URL of website and hostname as label



5
6
7
8
9
# File 'app/helpers/integral/mail_helper.rb', line 5

def website_url
  full_url = Rails.application.routes.default_url_options[:host]
  hostname = Addressable::URI.parse(full_url).host
  link_to hostname, full_url
end