This is the value retrieved from database :
<select id="approve" name="approval">
<option value="0">-- Please select one --</option>
<option value=Tan Ah Kau >Tan Ah Kau</option>
</select>
Here is my JSP :
<select id="approve" name="approval">
<option value="0">-- Please select one --</option>
<c:forEach items="${arrSta}" var="arrSta">
<option value=${arrSta.name} ${arrSta.name == selectedTutor ? 'selected' : ''}>${arrSta.name}</option>
</c:forEach>
</select>
The problem now is when I want to get the value from dropdownlist, the value supposed I get is Tan Ah Kau but now I only can get Tan .
Any idea ?
use quotes for value.