Created
November 11, 2019 08:00
-
-
Save bwonur/9940242101f36261dfcaaabb9560036b to your computer and use it in GitHub Desktop.
http or https
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php if (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' | |
| || $_SERVER['SERVER_PORT'] == 443) { | |
| // HTTPS | |
| } else { | |
| // HTTP | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment