Jump to content

https necessary or not


vikela

Recommended Posts

i am trying to figure out what does the following code and how best i can shorten it?it is part of a flash poll code.

$URL = ''; 
        $URL .= (($_SERVER['HTTPS'] != '') ? "https://" : "http://");
        $URL .= (($www == true && !preg_match("/^www\./", $_SERVER['HTTP_HOST'])) ? 'www.'.$_SERVER['HTTP_HOST'] : $_SERVER['HTTP_HOST']);

Link to comment
https://forums.phpfreaks.com/topic/157089-https-necessary-or-not/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.