-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
24 lines (22 loc) · 693 Bytes
/
index.php
File metadata and controls
24 lines (22 loc) · 693 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
<?php
$target = get_theme_mod('headless_redirect_uri');
function redirect($url, $statusCode = 303) {
header('Location: ' . $url, true, $statusCode);
die();
}
redirect($target, 301);
?>
<!DOCTYPE html>
<html>
<head>
<meta name="robots" content="noindex" />
<meta content="0;url=<?php echo $target; ?>" http-equiv="refresh"/>
<script type="text/javascript">
window.location = '<?php echo $target; ?>';
</script>
</head>
<body>
<h2>Redirecting you to the new website...</h2>
<p>Click <a href="<?php echo $target; ?>">here</a> you don't get redirected automatically.</p>
</body>
</html>