Hi Mary,
Sorry for the repeated posts in a short span of time, but I needed it urgently and thought that someone or the other may help.
I could not find the ids for links in the inspector of the browser, but I could solve my problem by commenting the code for displaying the user menu and preferences submenu items in the core_renderer.php file.
Thank you very much.