Opened 16 years ago

Closed 14 years ago

Last modified 14 years ago

#69 closed defect (fixed)

Language determination by Fusion.

Reported by: tgudmu Owned by: madair
Priority: P2 Milestone:
Component: Core Version: SVN
Severity: Minor Keywords:
Cc: Browser: All
External ID: Operating System: All
state: Analysing

Description

Fusion determines the locale of a client with the navigator.userLanguage which returns the language of the browser itself. What language it was set up while installed. The true locale of a user is only returned with a correct value in Internet Explorer 7 (and possibly other IE browsers).

Change History (7)

comment:1 by tgudmu, 16 years ago

A possibly better way would be to retrieve the locale through the HTTP header "Accept-Language" and could be done with an Ajax callback to a server side page that returns a list of Accepted-Languages which are the user's choice for locales.

comment:2 by madair, 16 years ago

Milestone: 1.0.72.0
state: NewAnalysing
Status: newassigned

load strings via php and detect accept-lang header

comment:3 by pagameba, 15 years ago

Mike is this done or at least doable for 2.0?

comment:4 by madair, 15 years ago

Browser: Firefox 2All
Version: 1.0.6SVN

this is doable for 2.0 with the caveats:

  • not doable if the map is using commercial layers only because there isn't necessarily any AJAX calls made to the server (MapGuide and MapServer both have a CreateSession.php interface that can be used for this
  • it would probably have to set it to the first lang code in the list, not do any fancy language setting based on the preferences in the list. (e.g. my default IE accept-language string is: "en-ca,en-us;q=0.8,fr;q=0.5,fr-ca;q=0.3", this would set language to en-CA if available, otherwise en.

Some parts of the page have already been rendered by the time CreateSession is called and may require a redraw.

comments?

comment:5 by madair, 15 years ago

if there are no comments I'll go ahead and commit what I have

comment:6 by madair, 14 years ago

Milestone: 2.02.1
Resolution: fixed
Status: assignedclosed

comment:7 by madair, 14 years ago

Milestone: 2.1

Milestone 2.1 deleted

Note: See TracTickets for help on using tickets.