Welcome Guest, Not a member yet? Register   Sign In
How can I add a port to a URL when accessing the /admin/ controller.
#2

[eluser]meigwilym[/eluser]
If you have a MY_Admin_Controller (or similar) try this in the __construct().

Code:
$uri = parse_url($_SERVER['PATH_INFO']);

if(!isset($uri['port'] || $uri['port'] != 'PORT') header("Location:http://domain.com:PORT/admin", 301);

But check that the server provides PATH_INFO correctly first.

Mei


Messages In This Thread
How can I add a port to a URL when accessing the /admin/ controller. - by El Forum - 01-31-2012, 02:17 PM



Theme © iAndrew 2016 - Forum software by © MyBB