title: Grails remotefunction to populate dropdownlist with Jquery
body: <p>am using jquery as the ajax library for my grails application. I got a dropdownlist that is populated from another dropdown but no value appear.</p>
  
  <p>GSP:</p>
  
  <pre><code>  &lt;label for="countryddl" &gt;Country:&lt;/label&gt;
    &lt;g:select name="countryddl" id="countryddl" from="${locations.country}"  
              keys ="${locations.country}"
              noSelection="['':'Select one...']"
             onChange="${remoteFunction( action:'updateProvince',
                                            params: '\'id=\'+escape(this.value)',
                                            update: [success: 'provinceddl'] )}"
  
    &gt;&lt;/g:select&gt; &lt;br/&gt;&lt;br /&gt;
      &lt;label for="provinceddl" &gt;Province:&lt;/label&gt;
    &lt;g:select name="provinceddl" id ="provinceddl" noSelection="['':'Select one...']" from=""&gt;&lt;/g:select&gt;
  </code></pre>
  
  <p>Controller:</p>
  
  <pre><code>def updateProvince = {
          def country = params['id']
          def locations = Location.findAllByCountry(country)
          render locations.province as JSON
  
      }
  </code></pre>