$(function() {
    
  $('#user-select').live('change', show_user_info);  
  show_user_info();
  
});

function show_user_info()
{ 
  var user_name = $('#user-select').val();

  if(user_name)
  {
    ShowProgressAnimation();
    $('#user-statistics').load(ajax_get_user_stats, "user_name="+user_name, function() {
      HideProgressAnimation();
    });  
  }
  else
  {
    $('#user-statistics').empty();
  }
}
