title: How to combine two fields to be displayed as options in a dropdown menu using jquery?
body: <p>I have a dropdown menu "Names". Right now, Im populating it with the firstName of employees. The first names of the employees is the data which is added at run time. Now I want to display the options in the dropdown as "(firstName) (lastName)" Is there a way to do this using jquery. Im able to retrive both the firstName and lastName from the database. </p>
  
  <p>Current Jquery Code for the dropdown:</p>
  
  <pre><code>$('.employeeName').prepend("&lt;option value=''&gt;&lt;/option&gt;").val('');
  for(i=0;i&lt;data.length;i++){
  if(data[i].firstName)
  $('.employeeName').append('&lt;option&gt;' + data[i].firstName  + '&lt;/option&gt;');
  }
  </code></pre>