I have a variable inside the javascript document.ready
function:
<script type="text/javascript">
$(document).ready(function() {
var xxxx= $("#yyyy").val();
alert(xxxx);
});
</script>
I want to use the above xxxx
variable in a JSP file. This is my JSP code which did not work:
<c:choose>
<c:when test="${xxxx == 'type'}">
........
</c:when>
<c:otherwise>
.......
</c:otherwise>
</c:choose>
Pleaase suggest me the method to use a javascript variable in a JSP file.