-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathquicksearch.php
79 lines (63 loc) · 1.79 KB
/
quicksearch.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
<?php
require_once(dirname(__FILE__). '/inc/common.php');
require(dirname(__FILE__) . '/inc/templates/search_process.php');
start();
?>
<div>
<div><h2>Quick Search</h2></div>
</div>
<?php
require(dirname(__FILE__) . '/inc/templates/searchform.php');
if (isset($term)) {
if($term=="") {
?><p>You did not enter any search term. A full listing of seeds is not supported.</p>
<?php
} else {
?>
<div>
<h2>Results</h2>
<p><strong>Search:</strong> <?php echo $term; ?><br />
<strong>Hits:</strong> <?php
echo $numrows;
if ($numrows>399) {
echo " (400 limit reached)";
}
?><p>
<?php if($numrows>0) {
echo "<p>";
$count=1;
// now you can display the results returned
while ($row=mysql_fetch_array($numresults)) {
$title = $row["title"];
$zurl = $row["url"];
$zid = $row["sid"];
$frequency = $row["frequency"];
$scope = $row["scope"];
$name = $row["name"];
$added = $row["added"];
$isArchived = $row["isArchived"];
if ($isArchived==1) {
$archived="yes";
} else {
$archived="no";
}
echo("<p>".$count.") <strong><a href=\"http://www.jdarchive.org/edit/?sid=$zid\">$title</a></strong> <br />");
echo("<strong>#".$zid." Added:</strong> ".$added." <strong>Name:</strong> ".$name." <strong>Frequency:</strong> ".$frequency." <strong>Scope:</strong> ".$scope." <strong>Archived: </strong>");
if ($archived=="yes") {
echo ("<a href='http://wayback.archive-it.org/2438/*/".$zurl."'>yes</a>");
} else { echo $archived; }
echo ("<br />");
echo("<a href=\"$zurl\">$zurl</a></p>");
$count++ ;
}
?>
</p>
<?php
} else {
echo "<br />";
} ?>
</div>
<?php
}
}
stop(4);