Back to Top
The nuts and bolts for
Creative web development

Set Locale ID

Sets the formatting of currency, date and time on a given web page by changing the Locale ID property. This overrides the web server's default settings.

Overview

So what does it do?
Sets the formatting of currency, date and time on a given web page by changing the Locale ID property. This overrides the web server's default settings. It does this by settting the ASP Session.LCID property of the Session Object.

Session.LCID Syntax

<% Session.LCID = 2058 %>

The number value matches a language setting.

Why should I use it?
Handy if you host your sites on US servers and want to have your content formatted for another country. English (British) will format currency in £ and give the date a format of dd/mm/yyyy.

How do I use it?
After installing the server bahaviour you can access it through the
Ultra-Dumb > Set Locale ID menu in the Server Behaviours panel.

Once lauched simply select a language from the drop down list. :)

Extra Info.
Thanks go to
Massimo for his Server Behavior Controls that enabled me to write this extension. Created by web chimps @ http://www.ultra-dumb.co.uk

Requirements

Type: Server Behavior
Product: UltraDev 4
Server Model: ASP VBScript


Share this Article

Reviews

RE: RE: RE: SessionLess ?

Hi Jacques,

Most of the information I have used for the extension  I have gained from the 4guys web site :) Check out this link to see more information on LCID:

http://www.4guysfromrolla.com/webtech/031401-1.2.shtml

Hope this helps - Jason :)

RE: RE: SessionLess ?

You have understood good.

But, I don't think that @LCID is scriptable.

Perhaps you should look further with the VBScript : SetLocale

Regards

RE: SessionLess ?

I'm not too sure what you mean by "session-less" Jacques? What I would say is that the sb I have created sets the Locale ID on a user-by user basis by using the session object. I suppose if your web server does not allow the use of the session object or varibles then it will not work :(

 I should really create another one that sets the LCID for a particular page not based on the session object but on the @LCID directive :) Hopefully get it done in the next few days :)

 

Thanks for your post Jacques - Jason

SessionLess ?

If think that this can't work with a session less Website

Regards

Jacques PYRAT