• Hello i want to use each li id in jquery i tried that is that right to get each li id in ajax call:

    var selected_tab = $(‘li’).find(‘a.selected’).attr(‘id’);

    var list = [];
    $(‘#apendata-‘+selected_tab+’ li’).each(function() {
    var id = $(this).attr(‘id’).split(‘-‘)[1];
    list.push(id);
    //alert(id);
    });

  • The topic ‘Want to add each li in loop using jquery’ is closed to new replies.