DrupalCustom

jsnew

Dec 12th, 2011
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $(document).ready(function populateTargetlangs() {
  2.   $("#edit-folks-list").change(function() {
  3.     var targetLangIndex = $(this).find(":selected").text();
  4.     var chunks = targetLangIndex.split("_");
  5.     var idChunk = chunks[1];
  6.    
  7.     $.getJSON('webDelegate.php?name='+ idChunk, function webServiceCaller(){
  8.       $.each(output, function(key, value) {  
  9.          $('#edit-targetLang-list').append($('<option>', { value : key }).text(value));});
  10.     });
  11.   });
  12. });
  13.  
Advertisement
Add Comment
Please, Sign In to add comment