plainblack.com
Username Password
search
Bookmark and Share
Adding SetLanguage bazaar item  (#10755)
Issue

can this be inplemented?

http://www.webgui.org/bazaar/contenthandler-setlanguage

Solution Summary
Added to WebGUI 7.8.3<br />
Resolved by perlDreamer
Comments
bartjol
0
8/12/2009 5:04 am
Oh, what I haven't done is make a test or found a way to reserve the scratch variable language. Of course I would like to help on this, but I am not sure what the preferred method is.
I would love to add more stuff if needed, when the rfe itself is agreed on,  I can continue with that.
JT
0
8/25/2009 4:04 pm
Could you explain the purpose of this? I get what it does, I'm just not sure of the intended use, and the Bazaar entry doesn't explain to me what it's used for either.

I'm sure you have a good use for it or you wouldn't have written it. So once I understand that, then I can approve or deny it.
bartjol
0
8/25/2009 4:43 pm
the intended use is to give mainly visitors (and maybe other users, let's say that a company has 1 account, with more people using it with different native languages) the ability to read the i18n messages in different languages. And this without need for template managers to create more templates with hardcoded messages, and writing out the html code for forms and other generated html, which defies the use of template variables.
For a fully internationalized sites, I believe this is necessary. I hope this makes it more clear.
JT
0
8/25/2009 4:53 pm
So the main purpose of this would be to allow users to switch the default language of Visitor (or their user account) from the primary language to some other language for multi-lingual sites?
bartjol
0
8/25/2009 4:57 pm
yes
bartjol
0
8/25/2009 5:00 pm
btw I'd love to implement it and write tests for it during the hackathon
JT
0
8/25/2009 5:04 pm
In that case it's approved, provided it can get some tests. Working on it during the hackathon would be cool too, because I'm thinking there might be a better way to do the integration work.
bartjol
0
8/25/2009 5:15 pm
testing and discussion on implementation time reserved during hackathon/ dutch dinner
bartjol
0
9/9/2009 11:14 am
made 3 methods in WebGUI::Session::Scratch
removeLanguageSetting
setLanguageSetting
getLanguageSetting

altered code sub new in International.pm and altered SetLanguage contentHandler to use the named method

next: writing tests
bartjol
0
9/9/2009 11:20 am
code available on http://www.bartjol.nl/home/setlanguage-stuff soon
bartjol
0
9/9/2009 12:21 pm
updated code, so it is not tried to set language 'delete'
bartjol
0
9/9/2009 1:36 pm
renamed methods, replaced Setting with Override
added tests for Scratch.t
bartjol
0
9/12/2009 1:15 pm
added tests for contenthandler on www.bartjol.nl/setlanguage-stuff
bartjol
0
9/14/2009 10:57 am
tests added for International.pm, nest pod for contentHandler
bartjol
0
9/14/2009 11:16 am
added pod in handler, uploaded file
JT
0
9/21/2009 3:24 pm
approved to be added in webgui 7.8
bartjol
0
10/2/2009 9:06 am
uploaded 6 files (based on 7.7.19) on http://github.com/BartJol/international- someone has to include those for me... Hopefully that can be managed
bartjol
0
10/13/2009 2:50 am
also made a macro and tested, which makes this contentHandler end-user friendly (makes links to the contenthandler for all installed WebGUI languages)
http://github.com/BartJol/PickLanguage-macro
http://www.webgui.org/bazaar/macro-picklanguage
bartjol
0
10/27/2009 5:53 am
added help and i18n file for PickLanguage macro, last thing todo: upgrade script and default template
bartjol
0
10/27/2009 7:55 am
added default template, and altered test expected result to match, all in git repo http://github.com/BartJol/international-
perlDreamer
0
10/28/2009 3:10 pm
Added to WebGUI 7.8.3
Resolved by perlDreamer
bartjol
5
10/29/2009 6:19 am
ah, nice, thank you
Details
Ticket Status Closed  
Rating5.0 
Submitted By bartjol  
Date Submitted2009-08-12 
Assigned To unassigned  
Date Assigned 2019-05-21  
Assigned By  
What to improve? WebGUI Beta  
URLrfe/request-for-enhancement/10755
Karma
Difficulty 1  
Karma So Far0
Karma Rank0.00
Keywords
Related Files
Ticket History
10/29/2009
11:19 AM
Closed bartjol
10/28/2009
8:10 PM
Resolved perlDreamer
8/25/2009
9:57 PM
Pending bartjol
8/25/2009
9:53 PM
Feedback Requested JT
8/25/2009
9:43 PM
Pending bartjol
8/25/2009
9:04 PM
Feedback Requested JT
8/12/2009
9:31 AM
Ticket created bartjol
© 2019 Plain Black Corporation | All Rights Reserved