Display a variable when a select box option is selected
- by user782104
For example, the select box
<select><option selected="" value="">Please Select</option><option value='txt'>Text</option><option value='int'>Numbers</option><option value='bool' >Boolean</option></select>
has a string
$messageList=array ( 'txt'=>'text message', 'int'=>'int message','bool'=>'bool message');
What i would like to achieve is to display correspond message when the optition is select?