Ajax help for success function
===

Hi I had just started to use Ajax and am getting an input from a textfield (id_title) in html to retrieve information from the database dynamically. It is now working fine when there is input in the textfield from the user, however when there is no input, the database still retrieves the first few records in the database. How can I prevent calling the success function when 'id_title' is empty?

Thanks!



	 function load_qn_search() {
		 $.ajax({
		   type: "GET",
		   url: '/qna/question_t_lookup/',
		   data: {
		 		query: $("#id_title").val()},
		   success: function(data) {			  
				   $('#ajax_reload_content').html(data);
		   },
		   statusCode: {
		     500: function() {
		       alert("Opps! There is a error!");
		     }
		   }
		 });
	};