getting full URL in php without white spaces
问题 I am trying to share the full URL from my website to whatsapp using mobile browser, I tried this to retrieve the full URL and it works perfectly when I echo the variable, but when I share using the mobile browser, it gives me the link with white space like this: http://127.0.0.1/?id= 40 which can not be opened, how can I get the full echoed link without no spaces? <?php $alink= (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://" . $_SERVER['HTTP_HOST'] . $