In that case if we want
to
like below:
Use JQuery:
$("#menu ul.sub-menu").each(function(){
$(this).removeClass('sub-menu');
});
Add class sub-menu item
use:
to
$("#menu ul.sub-menu").each(function(){
$(this).removeClass('sub-menu');
});