Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
New Contributor
Posts: 5
Registered: ‎10-31-2011
My Device: NA
My Carrier: NA

What's options are there for localisation?

I'm building a WebWorks version of an Android app that's localised into 39 languages.

 

At the moment all the localisations are in an xml file per language of key-value pairs.

Each language file has about 400 lines (roughly 40k per file).

 

Users can change the language used in app.

 

What options are there in WebWorks to solve this kind of situation?

 

I'd be more than happy to convert the resource files into any other kind of format to make working with it a better experience on the platform.

Retired
Posts: 518
Registered: ‎07-18-2011
My Device: Bold
My Carrier: Rogers

Re: What's options are there for localisation?

Hi TreeUK,

 

Off the top of my head you could change the files to JSON. If you want to use key/value pairs a great way to do this is HTML5 LocalStorage. If you want to backport the app to 5.0 and maintain the key/value pair interface you could look into lawnchair.



1.Please resolve your thread by clicking the "Accept as Solution" button below the post which solved your problem!
2. If any post helps you please click the button below the post(s)
New Contributor
Posts: 5
Registered: ‎10-31-2011
My Device: NA
My Carrier: NA

Re: What's options are there for localisation?

[ Edited ]

I should have specified I'm writing an app for BB mobile rather than PlayBook.

HTML 5 LocalStorage isn't an option for mobile by the looks of it.

 

Does BB Webworks have no built in solution for this?

 

What about the java based platform? I'll happily write a Javascript extension if there's a better solution available there.

Developer
Posts: 68
Registered: ‎03-01-2011
My Device: Not Specified

Re: What's options are there for localisation?

Hello TreeUK,

 

There's a persistence module for Blackberry Java though I don't encourage you to use a javascript extension for this since it IS possible for BB mobile to persistently store data through HTML 5 SQLite database. Here's some links on how to do this :

 

Blackberry HTML 5 Database : https://bdsc.webapps.blackberry.com/html5/apis/Database.html

Demo on how to use : http://www.html5rocks.com/en/tutorials/webdatabase/todo/

New Contributor
Posts: 5
Registered: ‎10-31-2011
My Device: NA
My Carrier: NA

Re: What's options are there for localisation?

This would work if there were a way to package a prepopulated database that ships with the app.

Otherwise I'd need to create scripts that insert ~1.5 mb of data on the first app run.

 

Is there a way to do this?