{% if editmode %}
<div class="pim-tooltip">
<div class="row">
<div class="col-9">
<div class="tooltip-description">
Footer Hintergrundbild:
</div>
{{ pimcore_relation("footer-bg-image", {"types":["asset"],"subtypes":{"asset":["image"]},"reload":true} ) }}
</div>
<div class="col-3">
<div class="tooltip-description">
Footer Schriftfarbe:
</div>
{{ pimcore_select("footer-font-color", {
"store" : [
['', 'Standard'],
['white', 'Hell'],
['dark', 'Dunkel']
],
"defaultValue" : "",
"reload" : true
}) }}
</div>
</div>
</div>
{% endif %}
{% set bgImage = pimcore_relation('footer-bg-image').getElement() is instanceof('\\Pimcore\\Model\\Asset') ? 'background-image:url(https://'~config.websiteDomain~pimcore_relation('footer-bg-image').getElement()~')' : '' %}
<footer class="bg-dark p-5 {{ pimcore_select('footer-font-color').getData }}" style="{{bgImage}}">
<div class="container">
<div class="row">
<div class="col-12 col-sm-12 col-lg-4">
{{ pimcore_inc('/alkanbari/Home/footer/footer-left') }}
</div>
<div class="col-12 col-sm-6 col-lg-4">
{{ pimcore_inc('/alkanbari/Home/footer/footer-center') }}
</div>
<div class="col-12 col-sm-6 col-lg-4">
{{ pimcore_inc('/alkanbari/Home/footer/footer-right') }}
</div>
</div>
<div class="copyright">
<div class="row">
<div class="col-12 text-center">
© 2023 {{'alkanbari-contact-company'|trans}} | {{'alkanbari-contact-name'|trans}} | <a href="#" data-bs-toggle="modal" data-bs-target="#modalImpressum">{{ 'alkanbari-impressum'|trans }}</a> | <a href="#" data-bs-toggle="modal" data-bs-target="#modalDatenschutz">{{ 'alkanbari-datenschutz'|trans }}</a>
</div>
</div>
</div>
</div>
<a class="scroll-top" href="#start"><span class="lsf">up</span></a>
</footer>
<!-- Modals -->
<div class="modal fade" id="modalImpressum" tabindex="-1" aria-labelledby="modalImpressumLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="modalImpressumLabel">{{ 'alkanbari-impressum'|trans }}</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
{{ pimcore_inc(config.siteImprintPath) }}
</div>
<div class="modal-footer">
</div>
</div>
</div>
</div>
<div class="modal fade" id="modalDatenschutz" tabindex="-1" aria-labelledby="modalDatenschutzLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="modalDatenschutzLabel">{{ 'alkanbari-datenschutz'|trans }}</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
{{ pimcore_inc(config.sitePrivacyPath) }}
</div>
<div class="modal-footer">
</div>
</div>
</div>
</div>
<!-- let's start javascripting -->
<script src="/themes/{{ config.template }}/js/jquery-3.6.0.min.js"></script>
<script src="/themes/{{ config.template }}/js/bootstrap.bundle.min.js"></script>
<script src="/themes/{{ config.template }}/js/jquery-scrollto.js"></script>
<script src="/themes/{{ config.template }}/js/jquery.inview.min.js"></script>
<script src="/themes/{{ config.template }}/js/jquery.fancybox.min.js"></script>
<script>
$().ready(function() {
// get enviroment dimensions
var viewportHeight = $(window).height();
var viewportWidth = $(window).width();
var displayHeight = $('html').height();
// re-adjust on resize ...
$(window).resize(function()
{
var viewportHeight = $(window).height();
var viewportWidth = $('html').width();
});
// navbar
$('#nav-icon3').click(function(){
$(this).toggleClass('open');
});
$('.navbar .nav-link').click(function() {
$('.navbar-collapse').removeClass('show');
$('#nav-icon3').removeClass('open');
});
// set gutters
$('.container-fluid.no-padding').addClass('gx-0');
// background images
$('.section-bg-image').each(function() {
var img = $(this).data('src');
$(this).css("background-image", "url('" + img + "')");
});
// scroll to
$('a[href*=\\#]').bind("click", function(event) {
event.preventDefault();
var target = $(this).attr("href");
if (!target.match(/slider(.*)/i)) {
$('html,body').animate({
scrollTop: $(target).offset().top
}, 2000);
}
});
$('.btn-continue').click(function() {
$(this).addClass('animate__animated animate__zoomOut');
});
// top bar
var minified = false;
$(window).scroll(function() {
var y = $(window).scrollTop();
// console.log('Y: ' + y);
if ( y > viewportHeight*.75 )
{
if ( minified == false )
{
$('.site-logo').addClass('logo-minified');
$('.navbar').addClass('navbar-minified');
minified = true;
}
}
else
{
$('.site-logo').removeClass('logo-minified');
$('.navbar').removeClass('navbar-minified');
minified = false;
}
});
// gallery
$('.gallery-image').mouseover(function() {
var e = $(this).find('.icon');
e.fadeIn();
}).mouseleave(function() {
var e = $(this).find('.icon');
e.fadeOut();
});
// animate on scroll
// animate on scroll
$('.scroll-animated').bind('inview', function(event, visible) {
if ( visible ) {
$(this).animate({
top: '0px',
opacity: 1
}, 600, 'swing');
}
});
// init animated
$('.animated').each(function() {
var a = $(this).data('animation');
$(this).addClass(a);
});
$('.animate__blurred').hide().fadeIn(4000);
// animate
$('.animated').bind('inview', function(event, visible) {
if ( visible ) {
var a = $(this).data('animation');
var d = ($(this).data('delay') != undefined && $(this).data('delay') != '') ? parseInt($(this).data('delay')) : 100;
var t = ($(this).data('timing') != undefined && $(this).data('timing') != '') ? parseInt($(this).data('timing')) : 500;
switch(a) {
case 'animate__fadeIn' :
$(this).delay(d).animate({
opacity: 1
}, t);
break;
case 'animate__slideInUp' :
$(this).delay(d).animate({
top: '0px',
opacity: 1
}, t);
break;
case 'animate__slideInLeft' :
$(this).delay(d).animate({
left: '0px',
opacity: 1
}, t);
break;
case 'animate__slideInRight' :
$(this).delay(d).animate({
right: '0px',
opacity: 1
}, t);
break;
};
}
});
// check form input
var formComplete = false;
$('.check-finput').keyup(function() {
$('.check-finput').each(function() {
// console.log('Check input: ' + $(this).attr('name') + ' -> ' + $(this).val() );
if ( $(this).attr('type')=='checkbox' && $(this).prop('checked')=='1' )
formComplete = true;
else if ( $(this).val() != '' )
formComplete = true;
else
formComplete = false;
});
if ( formComplete === true )
$('#submitBookingForm').animate({opacity:1}, 300); // fadeIn();
else
$('#submitBookingForm').animate({opacity:0}, 300); // fadeOut();
});
// submit form data
$('#submitBookingForm').click(function() {
var formToken = $('#contactToken').val();
var formFirstname = $('#contactFirstname').val();
var formLastname = $('#contactLastname').val();
var formEmail = $('#contactEmail').val();
var formEmailAddress = $('#emailAddress').val();
var formMessage = $('#contactMessage').val();
let formId = 'bookingForm';
let formFields = $('#'+formId).find('.check-finput').toArray();
let formQueryString = {};
for (i = 0; i < formFields.length; i += 1) {
console.log('Parse element ' + formFields[i].getAttribute('name') + ' -> value: ' + formFields[i].value);
input_id = formFields[i].getAttribute('name');
input_value = formFields[i].value;
formQueryString[input_id] = input_value;
}
$.ajax({
url : "/contact/alkanbari/sendmail",
type : "POST",
data : formQueryString,
dataType : "text",
success : function(data, jqXHR) {
console.log('Response: ' + data);
var r = data;
var s = JSON.parse(r);
console.log('Json: ' + s);
if (s.code == '400')
$('#submitContactMessage').html(s.message).fadeIn();
else
$('#bookingForm').html(s.message);
},
error : function(XMLHttpRequest, textStatus, errorThrown) {
$('#bookingForm').html('Es ist ein Fehler aufgetreten. Bitte kontaktieren Sie uns telefonisch oder per E-Mail');
}
});
});
});
</script>
<script language="javascript">
function setCookie(cname, cvalue, exdays) {
var d = new Date();
d.setTime(d.getTime() + (exdays*24*60*60*1000));
var expires = "expires="+ d.toUTCString();
document.cookie = cname + "=" + cvalue + ";" + expires + ";path=/";
}
function getCookie(c_name) {
var i, x, y, ARRcookies = document.cookie.split(";");
for (i = 0; i < ARRcookies.length; i++) {
x = ARRcookies[i].substr(0, ARRcookies[i].indexOf("="));
y = ARRcookies[i].substr(ARRcookies[i].indexOf("=") + 1);
x = x.replace(/^\s+|\s+$/g, "");
if (x == c_name) {
return unescape(y);
}
}
}
function validateEmail(email)
{
// var mailformat = /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$/;
if( email.match( /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/ ) )
return true;
else
return false;
}
{% if loadOSM is defined and loadOSM == true %}
let map = L.map('osmMap', {center: [50.2039, 9.8878], zoom: 7, });
L.tileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png', {
maxZoom: 19,
attribution: '© <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a>'
}).addTo(map);
{% for i,marker in locations %}
let marker{{i}} = L.marker([{{marker.getGeoData()|replace({";":","})}}],{'title':'{{marker.getName()}}'}).addTo(map).bindPopup('{{marker.getDescription()|replace({"\n":", "})|striptags}}');
{% endfor %}
// let latlngs = [[49.689429253827676, 8.980653446951512], [49.65004724900781, 8.9808893017223], [49.6502763063044, 9.018390210277586], [49.69064989162164, 9.019097774589948]];
// let polygon = L.polygon(latlngs, {color: 'blue'}).addTo(map).bindPopup('Gebiet Michelstadt <a href="/praxiseinrichtung" target="_blank">Mehr erfahren</a>');
// zoom the map to the polygon
// map.fitBounds(polygon.getBounds());
setTimeout(() => {
map.invalidateSize();
}, 100)
{% endif %}
</script>