jQuery new option needs sorting
<p>I've got two dropdowns, as a result of changing the first one it triggers a jquery change() that does a post with the company id from the first dropdown.  That then runs a sql query to get a list of people that work for that company and fills the select box with options.  This is working fine and I've got the sql query set to ORDER BY admin_name.  But when jquery starts inserting the options into the dropdown it appears to be sorting by the option value instead (admin_id). What can I do to keep the options ordered by the admin_name (the text of the option). Below is the jQuery code responsible for adding the options:</p>

<pre><code>$.post("listSignedBy.php", { company_id: company_id },
                function(data) {
                        alert(data); &lt;-- this shows that the data is sorted correctly by the admin name.
                        var select = $('#signed_by');
                        if(select.prop) {
                                  var options = select.prop('options');
                        }
                        else {
                                  var options = select.attr('options');
                        }
                        $('option', select).remove();

                        var obj = jQuery.parseJSON(data);
                                    options[options.length] = new Option('-- Select Signed By --', '');
                        $.each(obj, function(val, text) {
                                    options[options.length] = new Option(text, val);
                        });
                        select.val(selectedOption);

                });  
</code></pre>

<p>Thank you for any assistance and please let me know if you need any further information to help troubleshoot/fix.</p>

<p>As requested, example JSON data:</p>

<pre><code>{"19082":"Aaron Smith","19081":"Becky Doe"}
</code></pre>

<p>So in this case what I WANT is:</p>

<pre><code>&lt;option value='19082'&gt;Aaron Smith&lt;/option&gt;
&lt;option value='19081'&gt;Becky Doe&lt;/option&gt;
</code></pre>

<p>But instead of sorting by the text, it's sorting by the value so I get:</p>

<pre><code>&lt;option value='19081'&gt;Becky Doe&lt;/option&gt;
&lt;option value='19082'&gt;Aaron Smith&lt;/option&gt;
</code></pre>
