fix menu javascript events