We would like to know how to get form elements as associative array.
<!DOCTYPE html>
<html>
<head>
</head><!--from w w w . java 2 s .c o m-->
<body>
<form name="ff" action="" method="POST">
<input name="student[john]" value="John">
<input name="student[kofi]">
<input name="student[kwame]">
<input type="submit" name="submit">
</form>
<a onclick="console.log(document.ff['student[john]'].value);">click me <a>
</body>
</html>
The code above is rendered as follows: