473,505 Members | 15,381 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

multilanguage application

Hi all,

I need to develope a multilanguage application in javascript:
is there some particular library, or do you have some
pointer to guidelines to follows: the messages should
if possible be keeped in a separate file, one for language.
Is there some standard format?

thanks
giammy

May 25 '06 #1
2 4234
giangiammy wrote:
I need to develope a multilanguage application in javascript:
is there some particular library,
I don't know any.
or do you have some pointer to guidelines to follows: the messages
should if possible be keeped in a separate file, one for language.
Using one file per language compared to one file for all messages has
the advantage of quick loading of the application; it has the drawback
of requiring the application to reload (thereby losing all client-side
states unless backed up otherwise before, such as in a cookie or in a
server-side session variable) in order to change the user interface
language.
Is there some standard format?


No. But Object objects are your best bet, for example for a one-language
messages file:

var messages = {
msg_foobar: "This great Foo application frobnicates bar.",
...
}

You can then access the message with

messages.msg_foobar

or

messages["msg_foobar"]

where the latter is required if the property name is not an identifier.
HTH

PointedEars
--
Bill Gates isn't the devil -- Satan made sure hell
_worked_ before he opened it to the damned ...
May 26 '06 #2
giangiammy wrote:
Hi all,

I need to develope a multilanguage application in javascript:


What is the application? How is it supposed to work? I assume you mean
client-side JavaScript. What are you using on the server side? Can the
server side help implement the many languages? All of these answers
probably will affect your choices.

Peter

May 27 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
16655
by: Mariano López | last post by:
I'm trying to make a multilanguage website. When the user enters the site, I want to detect the language and automatically make a redirection. How can I do this? And how should I organize my data...
1
1958
by: Tosch | last post by:
I have to write a multilanguage application with the following criteria: - The language code can be set in a config file or similar. I don't want .NET do decide which language to use. This way...
7
4694
by: Mat | last post by:
I would like to build multilanguage applications -user may have options, in runtime to change the language(switch). -i may need to update languages (grammar..) without rebuild to applications. ...
1
1256
by: | last post by:
Could you be more precise? Do you want to print a pre- defined text or random text? Do you want the user to select it, or look it up in the regional settings of windows? >-----Original...
5
3032
by: Michal Táborský | last post by:
I am wondering, if it's effective to use text arrays to store multilanguage information. We used to do it like this: CREATE TABLE product ( id serial NOT NULL, price float4, ... )
2
1442
by: Pitaridis Aristotelis | last post by:
I would like to make a multilanguage project such a way that I will be able to give a sample text file to various pepole around the world in order to translate it in various language. How can I...
0
874
by: Emilio | last post by:
Hello all I'm developing an application in Visual Studio 2005 (VB code). (Web application with Sql Server as well) The application is Multilanguage based (4 languages or more) I don't know the...
1
2718
by: paolob | last post by:
I need to provide multilanguage support to my application. I alredy writed a multilanguage test application, using VS6 and resource only dll. Now i'm using Visual Studio 2005, I find out that it...
1
1118
by: Tomasz Grobelny | last post by:
I have a multilanguage application. Now it is compiled to one exe and satellite assemblies with translations. How do I pack all these resources into just one exe file that will contain resources...
0
7216
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7098
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7303
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7471
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5613
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4699
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3176
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1528
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
407
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.