working menu functionality