Recording button ID's in Javascript
<p>I am trying to create an item selection menu, where the user is presented with multiple buttons to pick their choices. I am creating several divs with PHP.</p>

<pre><code>     &lt;div id="h1-1"&gt;&lt;input type="button" value="h1-1" onclick="recordValue()"&gt;&lt;/div&gt;
     &lt;div id="h1-2"&gt;&lt;input type="button" value="h1-2" onclick="recordValue()"&gt;&lt;/div&gt;
</code></pre>

<p>I would like to record all the values of buttons pressed and show these values via Ajax.
Then when user is done selecting and presses submit I will insert these into MSSQL database.</p>

<ul>
<li>How do I record button values to an array with Javascript?</li>
<li>How do I then show what was pressed?</li>
<li>Where could I execute some filtering of the selections (e.g. if h1-1 was pressed i do not want them to be able to select h2-1) ?</li>
</ul>
