How to use jquery to replace textbox with select that gets information from database

replace a text box with a select that gets information from a database using jquery. the query from the database takes an argument

What you want to do can be done by reading the following

http://api.jquery.com/jQuery.ajax/ - Send the request to your script
http://api.jquery.com/replaceWith/ - Replace the text box with a select box
http://api.jquery.com/append/ - Append the li values to the select box

Thank you I will try. You were very helpful