-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdiatom.php
64 lines (52 loc) · 2.01 KB
/
diatom.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?php
// BIDDSAT - BIoDiversity DataSet Assessment Tool
// Copyright (C) 2012 Javier Otegui
// This file is part of BIDDSAT.
// BIDDSAT is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
// BIDDSAT is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with BIDDSAT. If not, see <http://www.gnu.org/licenses/>.
// Contact: javier.otegui@gmail.com
include 'header.php';
$filename=$path.'diatom.txt';
$datalink = checkFile($filename, $db, $prov, $dataset);
session_start();
$tipo='d';
$factor=7;
$punto=5;
$filename='./images/D'.substr($db, 5, 6).'P'.$prov.'R'.$dataset.'TD.png';
$thumbnailPath='./thumbs/D'.substr($db, 5, 6).'P'.$prov.'R'.$dataset.'TD.thumb';
$check=file_exists($filename);
if ($check==1) {
echo '<p>The image has been created. Click on the thumbnail below to see it full-size. You can download it by right-clicking and selecting "Save as..."</p>';
echo '<p><a href="'.$filename.'" target="_blank"><img src="'.$thumbnailPath.'" /></a></p>'.$datalink.'   '.$endbutton;
} else {
echo '
<html>
<head>
</head>
<body>
<p>Generating image...</p>
<form action="./muestrares.php?db='.$db.'&prov='.$prov.'&dataset='.$dataset.'" method="GET" name="frm">
<input type="hidden" name="t" value="'.$tipo.'" />
<input type="hidden" name="f" value="'.$factor.'" />
<input type="hidden" name="p" value="'.$punto.'" />
<input type="hidden" name="db" value="'.$db.'" />
<input type="hidden" name="prov" value="'.$prov.'" />
<input type="hidden" name="dataset" value="'.$dataset.'" />
</form>
<p>
<script language="JavaScript">
document.frm.submit();
</script>
</body>
</html>
';
}
?>