-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
54 lines (39 loc) · 1.33 KB
/
index.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
<!doctype html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Playfair+Display&family=Ubuntu&display=swap" rel="stylesheet">
<?php wp_head(); ?>
</head>
<?php
$google_analytics_tag = 'G-EC8J6TE56P'; // Default not production
if (!empty($_SERVER) && !empty($_SERVER['HTTP_HOST']) && $_SERVER['HTTP_HOST'] === 'nomadmystic.com') {
$google_analytics_tag = 'G-T307SL3RSD';
}
?>
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=<?php echo $google_analytics_tag; ?>"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
const googleTag = "<?php echo $google_analytics_tag; ?>";
gtag('config', googleTag);
</script>
<body <?php body_class(); ?>>
<?php wp_body_open(); ?>
<?php do_action('get_header'); ?>
<div id="app">
<page>
<?php echo view(app('sage.view'), app('sage.data'))->render(); ?>
</page>
</div>
<?php do_action('get_footer'); ?>
<?php wp_footer(); ?>
</body>
</html>