<?php
/*
if( $this->document->getTitle() ) {
// use the manually set title if available
$this->headTitle()->set( $this->document->getTitle() );
}
if( $this->document->getDescription() ) {
// use the manually set description if available
$this->headMeta()->appendName( 'description', $this->document->getDescription() );
}
*/
$this->headTitle()->setSeparator( ' | ' );
$actual_link = ( isset( $_SERVER[ 'HTTPS' ] ) ? "https" : "http" )."://".$_SERVER[ 'SERVER_NAME' ];
// Grab the last part of the URL for conditionally assigning SEO title/description.
$current_url_split = explode( "/", $_SERVER['REQUEST_URI'] );
$current_url_last = $current_url_split[ count( $current_url_split ) - 1 ];
// Check which SEO title/description to assign to this templated page.
if ( $current_url_last == "gallery" || strpos( $current_url_last, "gallery" ) ) {
$this->headTitle()->set( $this->property->getGallery_title() );
$this->headMeta()->appendName( 'description', $this->property->getGallery_desc() );
} elseif ( $current_url_last == "floorplans" || strpos( $current_url_last, "floorplans" ) ) {
$this->headTitle()->set( $this->property->getFloorplans_title() );
$this->headMeta()->appendName( 'description', $this->property->getFloorplans_desc() );
} elseif ( $current_url_last == "neighborhood" || strpos( $current_url_last, "neighborhood" ) ) {
$this->headTitle()->set( $this->property->getNeighborhood_title() );
$this->headMeta()->appendName( 'description', $this->property->getNeighborhood_desc() );
} elseif ( $current_url_last == "social" || strpos( $current_url_last, "social" ) ) {
$this->headTitle()->set( $this->property->getSocial_title() );
$this->headMeta()->appendName( 'description', $this->property->getSocial_desc() );
} elseif ( $current_url_last == "contact" || strpos( $current_url_last, "contact" ) ) {
$this->headTitle()->set( $this->property->getContact_title() );
$this->headMeta()->appendName( 'description', $this->property->getContact_desc() );
} else {
$this->headTitle()->set( $this->property->getTitle() );
$this->headMeta()->appendName( 'description', $this->property->getDescription() );
}
// Property Data
// $cache_data = json_decode( $this->property->getCache_property() );
// $property_data = $cache_data[ 0 ]->PropertyData;
// // Property Domain
// $property_domain = $this->property->getDomain();
// $property_subdomain_name = explode("/", explode(".", $property_domain)[0])[count(explode("/", explode(".", $property_domain)[0]))-1];
?>
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<?php if( $this->websiteConfig( 'NoIndexNoFollow' ) ) : ?>
<meta name="robots" content="noindex,nofollow" />
<?php endif; ?>
<?= $this->headTitle(); ?>
<?= $this->headMeta(); ?>
<link rel="icon" href="<?php echo $actual_link; ?>/favicon.ico" type="image/ico" />
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" />
<link rel="stylesheet" type="text/css" href="/theme/fonts/webfonts.css" />
<link rel="stylesheet" type="text/css" href="/theme/css/foundation.min.css" />
<link rel="stylesheet" type="text/css" href="/theme/css/jquery-ui.min.css" />
<link rel="stylesheet" type="text/css" href="/theme/css/slick.css" />
<link rel="stylesheet" type="text/css" href="/theme/css/slick-theme.css" />
<link rel="stylesheet" type="text/css" href="/theme/css/global.css" />
<script src="/theme/js/jquery.min.js"></script>
<script src="/theme/js/jquery-ui.min.js"></script>
<script src="/theme/js/jquery.cookie.min.js"></script>
<script src="/theme/js/isotope.pkgd.js"></script>
<script src="/theme/js/imagesloaded.pkgd.js"></script>
<?php /* INIT GOOGLE MAPS API */
/* CHECK FOR TOKEN */
if( !empty( $this->websiteConfig( 'google_token' ) ) ) :
/* TOKEN */
$google_setting = $this->websiteConfig( 'google_token' );
$google_token = $google_setting;
echo '<script type="text/javascript">'.
'( function( $ ) {'.
'$( function() {'.
/* CHECK FOR CALLBACK */
'if( typeof initMap == \'function\' ) {'.
/* CHECK FOR MAP */
//'if ( $("#map").length > 0 ) {'.
'var googleScript = document.createElement( "script" );'.
'googleScript.type = "text/javascript";'.
'googleScript.src = "https://maps.googleapis.com/maps/api/js?key='.$google_token.'&libraries=places&callback=initMap";'.
'googleScript.async = true;'.
'googleScript.defer = true;'.
'document.body.appendChild( googleScript );'.
'}'.
'} );'.
'} )( jQuery );'.
'</script>';
endif;
?>
<?php if( $_SERVER['SERVER_NAME'] == 'vanmetreapartments.com' ) : ?>
<!-- Global site tag (gtag.js) - Google Analytics -->
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-4293413-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-4293413-1');
</script>
<?php endif; ?>
</head>
<body>
<?php /* FADE-IN */ ?>
<script>
console.log( "Made by Grafik" );
$( 'html' ).css( { 'opacity' : 0 } );
$( window ).on( 'load', function() {
$( 'html' ).animate( { 'opacity' : 1 } );
} );
</script>
<?php /* GLOBAL APARTMENTS Header */ ?>
<?= $this->template( 'Includes/apartments-header.html.php' ) ?>
<div id="theme-root">
<?php /* HERO */ ?>
<?= $this->template( 'Yardi/property_hero.html.php' ) ?>
<?php /* INTRO */ ?>
<?= $this->template( 'Yardi/property_intro.html.php' ) ?>
<?php /* TABS */ ?>
<?= $this->template( 'Yardi/property_tabs.html.php' ) ?>
<?php /* NEARBY */ ?>
<?= $this->template( 'Yardi/property_nearby.html.php' ) ?>
<?php /* SEARCH AND FIND */ ?>
<?= $this->template( 'Yardi/property_find.html.php' ) ?>
<?php /* GLOBAL APARTMENTS FOOTER */ ?>
<?= $this->template( 'Includes/apartments-footer-popup.html.php' ) ?>
<?= $this->template( 'Includes/apartments-footer.html.php' ) ?>
</div>
<script src="/theme/js/what-input.min.js"></script>
<script src="/theme/js/foundation.min.js"></script>
<script src="/theme/js/slick.min.js"></script>
<script>$(document).foundation();</script>
</body>
</html>