Get Project Path with Protocol

Here is how you can absolute project url with for http and htts both:: $protocol = stripos($_SERVER[‘SERVER_PROTOCOL’],’https’) === true ? ‘https://’ : ‘http://’; echo $protocol.$_SERVER[‘HTTP_HOST’].$_SERVER[‘PHP_SELF’];