Added functions to return URL to click handler and execute