-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
header.php
59 lines (41 loc) · 2.12 KB
/
header.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
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo('charset'); ?>">
<meta name="viewport" content="width=device-width">
<link rel="profile" href="http://gmpg.org/xfn/11">
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>">
<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=Noto+Sans:ital,wght@0,100..900;1,100..900&family=Noto+Serif+TC:[email protected]&family=Noto+Serif:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
<?php wp_head(); ?>
</head>
<body <?php body_class('text-gray-900 antialiased'); ?>>
<!-- <img class="w-full h-screen overflow-hidden brightness-50 sticky top-0 -z-10" src="<?php echo get_template_directory_uri() ?>/img/bg2.jpg"/> -->
<!-- <img class="w-full overflow-hidden brightness-50 sticky top-0 -z-10" src="<?php echo get_template_directory_uri() ?>/img/bg1.jpg"/> -->
<?php
$bg1 = "bg-main";
$template="";
switch(get_the_title()) {
case "bio": $bg1 = "bg-home"; $template="bio"; break;
case "testimonials": $bg1 = "bg-three"; $template="testimonials"; break;
case "sellers": $bg1 = "bg-four"; $template="sellers"; break;
case "buyers": $bg1 = "bg-five"; $template="buyers"; break;
// case "contact": $bg1 = "bg_home"; $template="contact"; break;
} ?>
<div id="bg" bg1="<?php echo $bg1?>" bg2="bg-main" class="brightness-50 <?php echo $bg1?> bg-cover h-screen sticky top-0 -z-10">
</div>
<div class="-mt-[calc(100vh)]">
<?php do_action('realtyone_site_before'); ?>
<div id="page" class="min-h-screen flex flex-col">
<?php do_action('realtyone_header'); ?>
<?php get_template_part( 'template-parts/nav', get_post_format() ); ?>
<div id="content" class="site-content flex-grow">
<?php if (is_front_page()) { ?>
<?php get_template_part( 'template-parts/homepage', get_post_format() ); ?>
<?php } ?>
<?php if($template) {
get_template_part( 'template-parts/' . $template, get_post_format() );
} ?>
<?php do_action('realtyone_content_start'); ?>
<main class="bg-white text-slate-800">