this is my input text box
input type="text" id="country" name="country" class="input_text"
am fecting values from database country and state from jquery
var country;
jQuery(function(){
$("#country").autocomplete("countries.jsp");
});
it is working fine but the problem is onclick of drop down value it will display that value in textbox,while displaying in textbox it is taking 5 extra space in between country and state, any body tell me how can i trim this value having only one space in between country and state
EDIT
yes it is from server only in text box it is taking to much of space
try {
ResultSet rs = null;
java.sql.Statement stmtGet = null;
stmtGet = pg.gclsWFDbUtil.getDbConnection().createStatement();
String query = request.getParameter("q").toLowerCase();
String QueryString = "Select country,state from emp_master where country like '"
+ query +"%'";
rs = stmtGet.executeQuery(QueryString);
response.setHeader("Content-Type", "text/html");
while (rs.next()) {
out.print(rs.getString(1)+"");
out.print(rs.getString(2)+"\n");
}