This topic is locked

Language selector

1/20/2009 7:35:22 PM
ASPRunnerPro General questions
P
Philip author

Hi,

I wonder why the language selector is only included on the LIST page. I suggest to include it to MENU page as well because this is often the "entry point" to an application. Can we expect this in a future build please?
Regards,

Philip

J
Jane 1/21/2009

Philip,
you can add language dropdown on the menu page manually.

Add following code on the Visual Editor tab in HTML mode:

{mlang_message LANGUAGE}:

<SELECT {$langselector_attrs}>

<OPTION value="English" {$English_langattrs} selected id="replace_4">English</OPTION>

<OPTION value="French" {$French_langattrs} id="replace_5">French</OPTION>

<OPTION value="German" {$German_langattrs} id="replace_6">German</OPTION>

</SELECT>


Then add Menu page: Before display event on the Events tab.

Here is a sample:

if REQUEST("language")<> "" then SESSION("language")=REQUEST("language")

svar=GoodFieldName(mlang_getcurrentlang()) & "_langattrs"

xt.assign svar,"selected"

xt.assign "langselector_attrs","name=lang onchange=""java script: window.location='menu.asp?language='+this.options[this.selectedIndex].value"""