-
Notifications
You must be signed in to change notification settings - Fork 1
/
search.php
32 lines (31 loc) · 1.04 KB
/
search.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
<?php
include('header.php');
if(isset($_GET['keyword'])) {
if(substr_count($_GET['keyword'], ".") == '3') {
header('Location: searchByIP.php?ip='.$_GET['keyword']);
} else if(strlen($_GET['keyword']) == '32') {
header('Location: searchByID.php?id='.$_GET['keyword']);
} else if(var_dump(checkdate(strtotime($_GET['keyword'])))) {
header('Location: searchByDate.php?date='.$_GET['keyword']);
}
} else {
?>
<div class="container-fluid">
<div class="row">
<div class="col-sm-9 col-sm-offset-3 col-md-10 col-md-offset-2 main">
<h1 class="page-header">Search For Something</h1>
<div class="col-lg-6">
<div class="input-group input-group-lg">
<form action="#" method="get">
<input type="text" class="form-control" name="keyword" placeholder="Search By ID, IP, or Username">
<span class="input-group-btn">
<button class="btn btn-default" type="submit">Go!</button>
</span>
</div>
</div>
</div>
</div>
</div>
<?php
}
?>