-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
32 lines (29 loc) · 785 Bytes
/
index.php
File metadata and controls
32 lines (29 loc) · 785 Bytes
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
if (isset($_SERVER['HTTP_COOKIE'])) {
$cookies = explode(';', $_SERVER['HTTP_COOKIE']);
foreach($cookies as $cookie) {
$parts = explode('=', $cookie);
$name = trim($parts[0]);
setcookie($name, '', time()-1000);
setcookie($name, '', time()-1000, '/');
}
}
//header('Location: '.$_SERVER['HTTP_REFERER']);
if (isset($_SERVER['HTTP_REFERER'])) {
$redirect_url = $_SERVER['HTTP_REFERER'];
}
else {
$redirect_url = 'http://codecanaan.com/';
}
?>
<html>
<head>
<meta http-equiv="refresh" content="0;url=<?php echo $redirect_url ?>">
<script type="text/javascript">
location.href='<?php echo $redirect_url; ?>';
</script>
</head>
<body>
Redirect to <a href="<?php echo $redirect_url; ?>"><?php echo $redirect_url; ?></a>
</body>
</html>