Created and implemented page title helper function