for (i = 0; i < licount; i++) {
var lielem = $("#nitsmenu li").text();
var element = $(lielem).text();
$("#nitspopupmenu").append("<div class='form-group'><div class='pagesmenu selected'><span><i class ='fa fa-bars'></i>" + lielem + "");
}