| Current Path : /home/jeromecohp/www/templates/yootheme_jeromecourville/ |
| Current File : /home/jeromecohp/www/templates/yootheme_jeromecourville/index.php |
<?php
namespace YOOtheme;
defined('_JEXEC') or die();
// Set HTML5 output
$this->setHtml5(true);
/**
* @var Config $config
* @var View $view
*/
list($config, $view) = app(Config::class, View::class);
$config->addAlias('~site', '~theme.site');
$config->addAlias('~sidebar', '~theme.main_sidebar');
// Set view
$layout = $config('~theme.page_layout', '');
// Page
$attrs_page = [];
$attrs_page_container = [];
$attrs_image = [];
$attrs_media_overlay = [];
$attrs_page['class'][] = 'tm-page';
if ($config('~site.layout') == 'boxed') {
$attrs_page['class'][] = $config('~site.boxed.alignment') ? 'uk-margin-auto' : '';
$attrs_page['class'][] = $config('~site.boxed.margin_top') ? 'tm-page-margin-top' : '';
$attrs_page['class'][] = $config('~site.boxed.margin_bottom') ? 'tm-page-margin-bottom' : '';
$attrs_page_container['class'][] = 'tm-page-container uk-clearfix';
// Image
if ($config('~site.boxed.media')) {
$attrs_image = $view->bgImage($config('~site.boxed.media'), [
'width' => $config('~site.image_width'),
'height' => $config('~site.image_height'),
'size' => $config('~site.image_size'),
'position' => $config('~site.image_position'),
'visibility' => $config('~site.image_visibility'),
'blend_mode' => $config('~site.media_blend_mode'),
'background' => $config('~site.media_background'),
'effect' => $config('~site.image_effect'),
'parallax_bgx_start' => $config('~site.image_parallax_bgx_start'),
'parallax_bgy_start' => $config('~site.image_parallax_bgy_start'),
'parallax_bgx_end' => $config('~site.image_parallax_bgx_end'),
'parallax_bgy_end' => $config('~site.image_parallax_bgy_end'),
'parallax_easing' => $config('~site.image_parallax_easing'),
'parallax_breakpoint' => $config('~site.image_parallax_breakpoint'),
'parallax_target' => 'body',
]);
if ($config('~site.image_effect')) {
$attrs_image['class'][] = 'uk-position-cover uk-position-fixed';
} else {
$attrs_page_container = array_merge_recursive($attrs_page_container, $attrs_image);
$attrs_image = [];
}
// Overlay
if ($config('~site.media_overlay')) {
$attrs_page_container['class'][] = 'uk-position-relative';
$attrs_media_overlay['class'][] = 'uk-position-cover';
$attrs_media_overlay['style'] = "background-color: {$config('~site.media_overlay')};";
}
}
}
// Main section
$attrs_main_section = [];
$attrs_main_section['class'][] = 'tm-main uk-section uk-section-default';
$attrs_main_section['class'][] = $layout == 'blog' && $config('~theme.blog.padding') ? "uk-section-{$config('~theme.blog.padding')}" : '';
$attrs_main_section['class'][] = $layout == 'post' && $config('~theme.post.padding') ? "uk-section-{$config('~theme.post.padding')}" : '';
$attrs_main_section['class'][] = $layout == 'post' && $config('~theme.post.padding_remove') ? 'uk-padding-remove-top' : '';
// Main container
$attrs_main_container = [];
if ($layout == 'post') {
if ($config('~theme.post.width')) {
$attrs_main_container['class'][] = $config('~theme.post.width') == 'default' ? 'uk-container' : "uk-container uk-container-{$config('~theme.post.width')}";
}
} elseif ($layout == 'blog') {
if ($config('~theme.blog.width')) {
$attrs_main_container['class'][] = $config('~theme.blog.width') == 'default' ? 'uk-container' : "uk-container uk-container-{$config('~theme.blog.width')}";
}
} else {
$attrs_main_container['class'][] = 'uk-container';
}
?>
<!DOCTYPE html>
<html lang="<?= $this->language ?>" dir="<?= $this->direction ?>" vocab="https://schema.org/">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="shortcut icon" href="<?= $config('~theme.favicon') ?>">
<link rel="apple-touch-icon" href="<?= $config('~theme.touchicon') ?>">
<jdoc:include type="head" />
</head>
<body class="<?= join(' ', (array) $config('~theme.body_class')) ?>">
<?php if ($config('~site.layout') == 'boxed') : ?>
<div<?= $view->attrs($attrs_page_container) ?>>
<?php if ($attrs_image) : ?>
<div<?= $view->attrs($attrs_image) ?>></div>
<?php endif ?>
<?php if ($attrs_media_overlay) : ?>
<div <?= $view->attrs($attrs_media_overlay) ?>></div>
<?php endif ?>
<?php endif ?>
<?php if ($config('~site.layout') == 'boxed' && $config('~site.boxed.header_outside')) : ?>
<?= $view('~theme/templates/header') ?>
<?php endif ?>
<div<?= $view->attrs($attrs_page) ?>>
<?php if (!($config('~site.layout') == 'boxed' && $config('~site.boxed.header_outside'))) : ?>
<?= $view('~theme/templates/header') ?>
<?php endif ?>
<jdoc:include type="modules" name="top" style="section" />
<?php if (!$config('app.isBuilder')) : ?>
<div id="tm-main" <?= $view->attrs($attrs_main_section) ?> uk-height-viewport="expand: true">
<div<?= $view->attrs($attrs_main_container) ?>>
<?php if ($this->countModules('sidebar', true)) :
$grid = ['uk-grid'];
$grid[] = $config('~sidebar.gutter') ? "uk-grid-{$config('~sidebar.gutter')}" : '';
$grid[] = $config('~sidebar.divider') ? 'uk-grid-divider' : '';
?>
<div<?= $view->attrs(['class' => $grid, 'uk-grid' => true]) ?>>
<div class="uk-width-expand@<?= $config('~sidebar.breakpoint') ?>">
<?php endif ?>
<?php if ($config('~site.breadcrumbs')) : ?>
<?= $view->section('breadcrumbs') ?>
<?php endif ?>
<?php endif ?>
<jdoc:include type="message" />
<jdoc:include type="component" />
<?php if (!$config('app.isBuilder')) : ?>
<?php if ($this->countModules('sidebar', true)) : ?>
</div>
<?= $view('~theme/templates/sidebar') ?>
</div>
<?php endif ?>
</div>
</div>
<?php endif ?>
<jdoc:include type="modules" name="bottom" style="section" />
<?= $view->builder(json_encode($config('~theme.footer.content')), ['prefix' => 'footer']) ?>
</div>
<?php if ($config('~site.layout') == 'boxed') : ?>
</div>
<?php endif ?>
<!--SendinBlue-->
<script>
<?php
$formMessages = [
'fr-fr' => [
'required_code_error_message' => 'Veuillez choisir un code pays',
'locale' => 'fr',
'email_invalid_message' => 'Les informations que vous avez fournies ne sont pas valides. Veuillez vérifier le format du champ et réessayer.',
'required_error_message' => 'Vous devez renseigner ce champ.',
'generic_invalid_message' => 'Les informations que vous avez fournies ne sont pas valides. Veuillez vérifier le format du champ et réessayer.',
'selectedList' => 'liste sélectionnée',
'selectedLists' => 'listes sélectionnées'
],
'en-gb' => [
'required_code_error_message' => 'Please select a country code',
'locale' => 'fr',
'email_invalid_message' => 'The information you have provided is not valid. Please check the format of the field and try again.',
'required_error_message' => 'You must fill in this field.',
'generic_invalid_message' => 'The information you have provided is not valid. Please check the format of the field and try again.',
'selectedList' => 'selected list',
'selectedLists' => 'selected lists'
]
]
?>
window.REQUIRED_CODE_ERROR_MESSAGE = '<?php echo $formMessages[$this->language]['required_code_error_message'] ?>';
window.LOCALE = '<?php echo $formMessages[$this->language]['locale'] ?>';
window.EMAIL_INVALID_MESSAGE = window.SMS_INVALID_MESSAGE = "<?php echo $formMessages[$this->language]['email_invalid_message'] ?>";
window.REQUIRED_ERROR_MESSAGE = "<?php echo $formMessages[$this->language]['required_error_message'] ?>";
window.GENERIC_INVALID_MESSAGE = "<?php echo $formMessages[$this->language]['generic_invalid_message'] ?>";
window.translation = {
common: {
selectedList: '{quantity} <?php echo $formMessages[$this->language]['selectedList'] ?>',
selectedLists: '{quantity} <?php echo $formMessages[$this->language]['selectedLists'] ?>'
}
};
var AUTOHIDE = Boolean(0);
</script>
<script src="https://sibforms.com/forms/end-form/build/main.js"></script>
<!-- END: SendinBlue -->
<script type="text/javascript" id="corner-popup" src="templates/yootheme_jeromecourville/js/corner-popup.min.js"></script>
<jdoc:include type="modules" name="debug" />
</body>
</html>