adding getCurrentPageName function