multiselect icon indicating copy to clipboard operation
multiselect copied to clipboard

Cannot get the list of values currently selected

Open shengc5 opened this issue 5 years ago • 2 comments

For the life of me I couldn't figure out a way to get the list of selected values. Working off of the demo.html with no action and setIsEnbaled(true), document.querySelector('#testSelect1').value returns a single value of the first item in the list("2" in this case). document.multiselect('#testSelect1').value returns undefined. Am I doing something wrong here?

shengc5 avatar Jul 17 '20 02:07 shengc5

me exactly the same ..... :( have you solved this issue ??? or could someone help us in this, please

marwanelsamman avatar Jul 28 '20 23:07 marwanelsamman

Probably a mistake:

<div class="userbox" id=ub_18 onchange="UpdateDatabase(proj_id.value,proj_publ_list.id,proj_publ_list.value)">
	<select id="proj_publ_list" name="proj_publ_list" multiple>  
		<list:forEach items="${proj_publ}" var="publications">
			<option value="${publications}"><list:out value="${publications}" /></option>
		</list:forEach>
	</select>
</div>

The value needs to be called from "id" of select. The onchange method is pointing to the div

Jesfreric avatar Aug 11 '20 22:08 Jesfreric