aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/Page.pm
diff options
context:
space:
mode:
authorlouise <louise>2009-08-31 14:19:42 +0000
committerlouise <louise>2009-08-31 14:19:42 +0000
commit21388c300397ffa23c31a4f3e401a88893000e3a (patch)
treece217c3f21229bc8bfd5a66a621da034912f050f /perllib/Page.pm
parentea25a8dfa3ef10f3fe3f38705e9342c1b2ce04fe (diff)
Delegating language and text domain settings to cobrands
Diffstat (limited to 'perllib/Page.pm')
-rw-r--r--perllib/Page.pm11
1 files changed, 3 insertions, 8 deletions
diff --git a/perllib/Page.pm b/perllib/Page.pm
index 10ba6f084..6d6c6a94d 100644
--- a/perllib/Page.pm
+++ b/perllib/Page.pm
@@ -6,7 +6,7 @@
# Copyright (c) 2006 UK Citizens Online Democracy. All rights reserved.
# Email: matthew@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: Page.pm,v 1.165 2009-08-31 12:22:54 louise Exp $
+# $Id: Page.pm,v 1.166 2009-08-31 14:19:42 louise Exp $
#
package Page;
@@ -104,13 +104,8 @@ sub microsite {
$q->{site} = $cobrand if $host =~ /$cobrand/;
}
- if ($q->{site} eq 'emptyhomes') {
- my $lang;
- $lang = 'cy' if $host =~ /cy/;
- $lang = 'en-gb' if $host =~ /^en\./;
- mySociety::Locale::negotiate_language('en-gb,English,en_GB|cy,Cymraeg,cy_GB', $lang);
- mySociety::Locale::gettext_domain('FixMyStreet-EmptyHomes');
- mySociety::Locale::change();
+ if ($q->{site} ne 'fixmystreet') {
+ Cobrand::set_lang_and_domain($q, $host);
} else {
mySociety::Locale::negotiate_language('en-gb,English,en_GB|nb,Norwegian,nb_NO'); # XXX Testing
mySociety::Locale::gettext_domain('FixMyStreet');