If i were you I'll use data-menuItem1, data-menuItem2, data-menuItem3... etc. attribute to find correct li. In other words you should update your HTML markup.