Bug 12534 - PROG/CCSR deprecation: Make getlanguages() theme independent for opac
authorBernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Sun, 6 Jul 2014 23:21:43 +0000 (20:21 -0300)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Mon, 14 Jul 2014 12:01:08 +0000 (09:01 -0300)
commitc3c7068709177408af59fb4e9538f623ba945a18
tree36d0f2b13ebe5844a065c397aa25830d957e85d6
parent61dc0ab223aa2a3e83bf980cd5616a325e03871a
Bug 12534 - PROG/CCSR deprecation: Make getlanguages() theme independent for opac

This patch removes a reference to prog theme on getlanguages()
when ENV var HTTP_ACCEPT_LANGUAGE is checked.

Changed to use sysprefs to find theme for opac and intranet

To test:
1) Apply the patch
2) Translate for a couple of languages: de-DE, fr-FR, es-ES, etc
3) Enable those languages for OPAC on I18N prefs
4) Using Firefox, clean all history/cookies
5) Change variable intl.accept_languages (will do several times)
 a) got to about:config
 b) search 'lang'
 c) look for the variable, double click, change to 'de-DE'
6) Go to opac page, must load in german
7) Repeat for each translated lang: clean > change val > reload opac
   On each case opac must load on configured language
8) Just to test, set variable on untranslated lang, opac page
must load on first value of list of enabled languages
9) prove t/Languages.t

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/Languages.pm