TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Oscar Wild
NA
3
2.4k
Javascript localization
Jan 31 2013 11:32 PM
Hello everyone! Can anyone help me with localization on javascript in Visual Studio?
I have a simple Visual Studio web application. Programming language is C#. I want to do something like adding 3 javascripts to the page. One in russian, one in english and one in kazakh. For example: <script type="text/javascript" src="englishLanguage.js" /> In "englishLanguage.js" would be all my English variables. And on the page, I would get those variables. However, I wasn't able to do so.
In aspx page in the head, I am adding some scripts.
<script runat="server" type="text/javascript" src="russianLanguage.js" charset="utf-8" > </script>
<script runat="server" type="text/javascript" src="englishLanguage.js" charset="utf-8" > </script>
<script type="text/javascript">
Some function to retrieve the variable from those scripts based on the current culture (englishLanguage.js,russianLanguage.js)
</script>
In those scripts lies the simple string: var uilanguage = { someString: "russian string" }; --- for russianLanguage.js
var uilanguage = { someString: "english string" }; --- for englishLanguage.js
Any example would be helpful!
Please help!
Thanks!
Reply
Answers (
2
)
how to retrive data from database using javascript]
MVC 4 Validation during Edit record