how use for loop in append attribute in jquery 1

how use for loop in append attribute in jquery

$('#date').append(
    '');

Here is what the above code is Doing:
1. It’s creating a select element with an id of date.
2. It’s creating an option element with a value of 0 and the text of – – SELECT – -.
3. It’s looping through the data that was returned from the server.
4. It’s creating an option element with a value of the date_time and the text of the date_time.
5. It’s closing the select element.

Similar Posts