Convert the javascript function into jquery
<p>i have one javascript function which are set drop down and textboxe from this fuction , i wanted to convert this function into jquery kindly assist.</p>

<pre><code>function setDDls(strCity, strState, strCountry) {
    $(txtCity).val(strCity);
    $(ddlState).val(strState);
    $(ddlCountry).val(strCountry);
    $("#overlay .close").click();
    return false;

    txtCitySearch = document.getElementById("&lt;%= txtCity.ClientID %&gt;");
    ddlStateSearch = document.getElementById("&lt;%= ddlState.ClientID %&gt;");
    ddlCountrySearch = document.getElementById("&lt;%= ddlCountry.ClientID %&gt;");
    txtCitySearch.value = strCity;

    ddlStateSearch.selectedIndex = 0

    for (i = 0; i &lt; ddlStateSearch.options.length; i++) {

        if (ddlState.options(i).text.toUpperCase() == strState.toString().toUpperCase()) {
            ddlStateSearch.selectedIndex = i;
            break;
        }
    }

    ddlCountrySearch.selectedIndex = 0;
    for (i = 0; i &lt; ddlCountrySearch.options.length; i++) {
        if (ddlCountrySearch.options(i).text.toUpperCase() == strCountry.toString().toUpperCase()) {
            ddlCountrySearch.selectedIndex = i;
            break;
        }
    }
    $("#overlay .close").click();
    return false;
}
</code></pre>
