1
|
<?php
|
2
|
require_once dirname(__FILE__)."/util.php";
|
3
|
|
4
|
$self_dir = ensure_suffix("/", dirname($_SERVER["SCRIPT_NAME"]));
|
5
|
|
6
|
function to_dir($path) { return dirname($path.'_'/*in case no filename*/); }
|
7
|
|
8
|
$h_level = 5;
|
9
|
$root = $_SERVER["SERVER_NAME"].rm_suffix("/", $self_dir)."?";
|
10
|
|
11
|
function add_ns($name, $path_pat)
|
12
|
{
|
13
|
global $root, $h_level, $path;
|
14
|
|
15
|
print("<h".$h_level.' id="'.$name.'">'.$root.'<big><a href="http://'.$root
|
16
|
.$name.'">'.$name."</a></big><i>".$path_pat."</i></h".$h_level.">\n");
|
17
|
}
|
18
|
|
19
|
ob_start(); // delay output in case there is a redirect
|
20
|
?>
|
21
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
22
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
23
|
<head>
|
24
|
<title>VegPath</title>
|
25
|
<link rel="stylesheet" type="text/css" href="/main.css" />
|
26
|
<style type="text/css">
|
27
|
h1 {color: green;}
|
28
|
</style>
|
29
|
<script type="text/javascript" src="/util.js"></script>
|
30
|
</head>
|
31
|
<body>
|
32
|
<h1>VegPath <small><a href="http://en.wikipedia.org/wiki/PURL">persistent URLs</a> for vegetation resources</small></h1>
|
33
|
<div>Supported URL patterns: <small>(elements in <i>italics</i> are optional)</small></div>
|
34
|
<?php
|
35
|
# list URLs
|
36
|
?>
|
37
|
<table border="0" cellspacing="0" cellpadding="0">
|
38
|
<tr valign="top">
|
39
|
<td nowrap="nowrap"><h2>Terms</h2></td>
|
40
|
<td nowrap="nowrap"><h2> </h2></td>
|
41
|
<td nowrap="nowrap"><h2>Data</h2></td>
|
42
|
</tr>
|
43
|
<tr valign="top">
|
44
|
<td nowrap="nowrap">
|
45
|
<?php
|
46
|
print("<blockquote>\n");
|
47
|
print("<h3>Exchange schemas</h3>");
|
48
|
{
|
49
|
print("<blockquote>\n");
|
50
|
add_ns("VegCore", ".term");
|
51
|
add_ns("DwC", ".term");
|
52
|
{
|
53
|
print("<blockquote>\n"); $h_level++;
|
54
|
add_ns("DwC.history", ".term");
|
55
|
print("</blockquote>\n"); $h_level--;
|
56
|
}
|
57
|
add_ns("TCS", "#/XPath");
|
58
|
add_ns("VegX", "#/XPath");
|
59
|
print("</blockquote>\n");
|
60
|
}
|
61
|
print("<h3>Aggregators</h3>");
|
62
|
{
|
63
|
print("<blockquote>\n");
|
64
|
add_ns("TNRS", ".term");
|
65
|
add_ns("VegBank", ".table.column");
|
66
|
add_ns("SALVIAS", ".table.column");
|
67
|
{
|
68
|
print("<blockquote>\n"); $h_level++;
|
69
|
add_ns("SALVIAS.db", ".table.column");
|
70
|
add_ns("SALVIAS.users", ".table.column");
|
71
|
print("</blockquote>\n"); $h_level--;
|
72
|
}
|
73
|
add_ns("VegBIEN", ".table.column");
|
74
|
add_ns("BIEN2", "");
|
75
|
{
|
76
|
print("<blockquote>\n"); $h_level++;
|
77
|
add_ns("BIEN2.web", ".table.column");
|
78
|
add_ns("BIEN2.core", ".table.column");
|
79
|
add_ns("BIEN2.geoscrub", ".table.column");
|
80
|
add_ns("BIEN2.staging", ".table.column");
|
81
|
print("</blockquote>\n"); $h_level--;
|
82
|
}
|
83
|
print("</blockquote>\n");
|
84
|
}
|
85
|
print("<h3>Primary databases</h3>");
|
86
|
{
|
87
|
print("<blockquote>\n");
|
88
|
add_ns("CTFS", "");
|
89
|
{
|
90
|
print("<blockquote>\n"); $h_level++;
|
91
|
add_ns("CTFS.schema", ".table.column");
|
92
|
add_ns("CTFS.tables", ".table");
|
93
|
add_ns("CTFS.terms", ".term");
|
94
|
print("</blockquote>\n"); $h_level--;
|
95
|
}
|
96
|
add_ns("IH.db", ".term");
|
97
|
print("</blockquote>\n");
|
98
|
}
|
99
|
print("<h3>People</h3>");
|
100
|
{
|
101
|
print("<blockquote>\n");
|
102
|
add_ns("Brad", "");
|
103
|
{
|
104
|
print("<blockquote>\n"); $h_level++;
|
105
|
add_ns("Brad.attribution", ".term");
|
106
|
add_ns("Brad.provenance", ".term");
|
107
|
add_ns("Brad.identifiers", ".term");
|
108
|
add_ns("Brad.identifier_examples", ".term");
|
109
|
print("</blockquote>\n"); $h_level--;
|
110
|
}
|
111
|
print("</blockquote>\n");
|
112
|
}
|
113
|
print("</blockquote>\n");
|
114
|
?>
|
115
|
</td>
|
116
|
<td nowrap="nowrap"></td>
|
117
|
<td nowrap="nowrap">
|
118
|
<?php
|
119
|
print("<blockquote>\n");
|
120
|
print("<h3>Institutions</h3>");
|
121
|
{
|
122
|
print("<blockquote>\n");
|
123
|
add_ns("IH", ".herbarium_code");
|
124
|
print("</blockquote>\n");
|
125
|
}
|
126
|
print("</blockquote>\n");
|
127
|
?>
|
128
|
</td>
|
129
|
</tr>
|
130
|
</table>
|
131
|
<?php
|
132
|
if (ends_with($root, '#')) # URL shortener requires fragment redirect
|
133
|
{
|
134
|
?>
|
135
|
<script type="text/javascript">
|
136
|
var loc = document.location
|
137
|
if (loc.hash) document.location = '?'+rm_prefix('#', loc.hash)
|
138
|
</script>
|
139
|
<?php
|
140
|
}
|
141
|
?>
|
142
|
<p> </p>
|
143
|
<?php
|
144
|
ob_end_flush();
|
145
|
|
146
|
# full directory index
|
147
|
fpassthru(fopen(to_dir($_SERVER["SCRIPT_URI"])."/all", "r"));
|
148
|
?>
|
149
|
</body>
|
150
|
</html>
|