I am using a list box which is having some options like english, arabic and so on.
When user selects the language, I want to run the java script function which will get the selected value. Here is the code
<?require_once ROOT_PATH . '/language/default/lang_default_full.php'?>;
<?require_once ROOT_PATH . '/language/ar/lang_ar_full.php'?>;
please help me out to solve this problem
Thanks & Regards
You almost have it, when searching for a selected value within a select box there is an extra method which needs to be used as well and its called options. See how the below goes for you.
var test = document.loginform.s1.options[document.loginform.s1.selectedIndex].value;