dropdown language
Posted: Sat Sep 08, 2018 8:18 am
HI guys,
I use a select object to display month names in a select field and these must appear in the language of the user. How can I build the SQL statement so that by default the column mt_de is used, if French is set as language, the column mt_fr has to be displayed in the dropdown.
My months table If the user's language is French, this SQL has to be run:
In all other cases, this one.
How to combine them?
I use a select object to display month names in a select field and these must appear in the language of the user. How can I build the SQL statement so that by default the column mt_de is used, if French is set as language, the column mt_fr has to be displayed in the dropdown.
My months table If the user's language is French, this SQL has to be run:
Code: Select all
SELECT `mt_id`,`mt_fr` FROM `months_names`
Code: Select all
SELECT `mt_id`,`mt_de` FROM `months_names`