Created
April 2, 2015 01:10
-
-
Save uzegonemad/37f12c3ea9f909c2b84c to your computer and use it in GitHub Desktop.
link-shorteners-and-a-call-to-action
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
ln -s /www/work.domain /www/buze.co |
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 | |
$host = $_SERVER['HTTP_HOST']; | |
if($host == 'work.domain') { | |
header('Location: http://work.domain'); | |
} elseif($host == 'buze.co') { | |
header('Location: //buzelac.com'); | |
} else { | |
echo 'Nothing to see here.'; // this is a fallback just in case | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment