Project

General

Profile

« Previous | Next » 

Revision 9601

web/index.php: removed no longer needed custom alias j.mp/vegpath# for when page reached through vegbiendev.nceas.ucsb.edu, because vegpath.org is a much more reliable domain than the previous path.vg, and a separate way to reach VegPath when path.vg is down is no longer needed

View differences:

web/index.php
3 3

  
4 4
$self_dir = ensure_suffix("/", dirname($_SERVER["SCRIPT_NAME"]));
5 5

  
6
# config
7
$alias = "j.mp/vegpath#";
8

  
9 6
function by_prefix($url, $main_url=null)
10 7
{
11 8
	if (!isset($main_url)) $main_url = $url;
......
17 14
}
18 15

  
19 16
$h_level = 5;
20
$root = $_SERVER["SERVER_NAME"] === gethostbyaddr($_SERVER["SERVER_ADDR"])
21
	? $alias : $_SERVER["SERVER_NAME"].rm_suffix("/", $self_dir)."?";
17
$root = $_SERVER["SERVER_NAME"].rm_suffix("/", $self_dir)."?";
22 18
# instead of PATH_INFO, to support the Apache ErrorDocument directive
23 19
$rel_fs_path = rm_prefix($self_dir, $_SERVER["REQUEST_URI"]);
24 20
$path = parse_dot_path($rel_fs_path);

Also available in: Unified diff