broker_ace_pages.php
2.51 KB
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
<?php
/*
* Template Name: Broker ACE Pages
*/
global $user_ID;
get_currentuserinfo();
if (!$user_ID) {
auth_redirect();
}
?>
<?php get_header("brokerlanding");
global $wpdb;
$currentTab = '';
if (isset($_GET['current_tab'])) {
$currentTab = $_GET['current_tab'];
} else {
$currentTab = 'ace_body_shop';
}
$bodyShopURL = home_url('/ace?current_tab=ace_body_shop');
$propertyContractorURL = home_url('/ace?current_tab=ace_property_contractor');
?>
<div id="brokercontent">
<div class="row">
<?php include_once 'broker_sidebar.php';?>
</div>
<div class="row">
<?php include_once 'broker_sidebar_tab.php';?>
</div>
<div id="page-content">
<h5 style="text-transform:uppercase;"><?php the_title();?></h5>
<?php get_template_part('loop', 'single');?>
<div class="ace-tabs ace-tabs-style-default" data-active="<?php echo $currentTab === 'ace_body_shop' ? '1' : '2' ?>">
<div class="ace-tabs-nav">
<a href="<?php echo $bodyShopURL; ?>" class="<?php echo $currentTab === 'ace_body_shop' ? 'ace-tabs-current' : '' ?>" data-target="self">ACE BODY SHOP</a>
<a href="<?php echo $propertyContractorURL; ?>" class="<?php echo $currentTab === 'ace_property_contractor' ? 'ace-tabs-current' : '' ?>" data-target="self">ACE PROPERTY CONTRACTOR</a>
</div>
<div class="ace-tabs-panes">
<div class="ace-tabs-pane ace-clearfix" style="<?php echo $currentTab === 'ace_body_shop' ? 'display:block;' : 'display:none;' ?>">
<?php
if ($currentTab === 'ace_body_shop') {
echo do_shortcode('[wpsl category="ace_body_shop"]');
}
?>
</div>
<div class="ace-tabs-pane ace-clearfix" style="<?php echo $currentTab === 'ace_property_contractor' ? 'display:block;' : 'display:none;' ?>">
<?php
if ($currentTab === 'ace_property_contractor') {
echo do_shortcode('[wpsl category="ace_property_contractor"]');
}
?>
</div>
</div>
</div>
</div>
<?php
if (function_exists(clean_custom_menus())) {
clean_custom_menus();
}
?>
</div>
<div class="new-footer-box">
<div class="left-image-menu"><a href="<?php echo site_url(); ?>/lets-connect-info/"></a></div>
<?php wp_nav_menu(
array(
'theme_location' => 'broker-footer',
'container' => 'nav',
'container_id' => 'broker-footer',
)
);
?>
</div>
<style>
html {
margin-top : 32px !important;
}
</style>
<?php get_footer();?>