Launch the existing website with different Logo, name and URL
I’m having an existing website. Now I want to launch this same website with a new name, URL & logo in Canada. The difference would be only URL, name and logo. Rest everything (App, DB, layout, server etc.) will remain same.
I developed the website in ruby on rails 3.2. What is the BEST way to get this done ?
if a user comes at www.existing.come will be able to see the existing layout
if a user comes at www.forcanada.com. it will load the same website but different logo n name
One Solution collect form web for “Launch the existing website with different Logo, name and URL”
You could use the I18n mechanic for it. Do something like the following code in the controller:
class ApplicationController < ActionController::Base protect_from_forgery before_filter :set_locale private def set_locale case request.host.split('.').last when 'de' I18n.locale = :de when 'com' I18n.locale = :en else I18n.locale = I18n.default_locale end end end
index.en.html.erb for the different views. You can create your own “language” for each site.
de are just examples.