Append option values to a hidden field?
<p>With the push of a button, I'm iterating through a list of options in a select. I wish to append all of these option (values of the options) to a hidden fields, separated by a pipe <code>|</code>. So far I've come up with this, however, It just puts the last value of the option in the select in the hidden field?</p>

<pre><code>//Select all cities
$jq("input#checkcities").click(function () {

    $jq(".select-cities &gt; option").each(function () {
        var zipCodeValue = $jq(this).val();

        $jq(".select-cities option").attr("selected", "selected");
        $jq(".select-cities option").appendTo(".chosen-cities");

        //Put value of cities in hidden field.
        $jq('.hiddenFieldChosenCities').val(zipCodeValue);

    });
});
</code></pre>
