/** * Lets you specify the callback url to redirect to when authorizing the page is reloaded. * If the url is not specified and is used to redirect the authorization, * the authorization after the current page just updated * * @param string $url page that will be implemented to redirect after login (accept QUERY_STRING) * @return $this */ public function setUrl($url = '') { if (is_array($url) === true) { $url = $url[key($url)]; } $request = new Request(); if (empty($url) === true) { $this->url = $request->getScheme() . '://' . $request->getHttpHost() . (new Router())->getRewriteUri(); } else { $this->url = $request->getScheme() . '://' . $request->getHttpHost() . $url; } return $this; }
public function getScheme() { return parent::getScheme(); }