120 lines
4.5 KiB
PHP
120 lines
4.5 KiB
PHP
<?php
|
|
/**
|
|
* @var string $content
|
|
* @var \yii\web\View $this
|
|
*/
|
|
|
|
use app\models\Ts;
|
|
use app\widgets\Content;
|
|
use app\widgets\Footer;
|
|
use app\widgets\Header;
|
|
|
|
?>
|
|
<!doctype html>
|
|
<html lang="bg-BG">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport"
|
|
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
|
<title><?= Yii::$app->controller->pageTitle ?></title>
|
|
<meta name="keywords" content="">
|
|
<meta property="og:title" content="<?= Yii::$app->controller->pageTitle ?>">
|
|
<meta property="og:type" content="article">
|
|
<meta property="og:url" content="<?= Yii::$app->params['portal'] ?>">
|
|
<meta property="og:image" content="<?= Yii::$app->controller->img ?>">
|
|
<meta property="og:site_name" content="Nasledstvo BG">
|
|
<meta property="og:description" content="<?= Yii::$app->controller->description ?>">
|
|
<meta name="apple-mobile-web-app-title" content="AppTitle">
|
|
<meta name="apple-mobile-web-app-capable" content="yes">
|
|
<meta name="apple-mobile-web-app-status-bar-style" content="black">
|
|
|
|
<link rel="stylesheet" href="/_public/assets/css/portal.css">
|
|
<link rel="stylesheet" href="/_public/assets/css/footer.css">
|
|
<link rel="stylesheet" href="/_public/assets/css/website-responsive.css">
|
|
<script src="https://unpkg.com/pdfjs-dist/build/pdf.min.js"></script>
|
|
|
|
<script src="/_public/assets/js/default.js"></script>
|
|
<script src="/_public/assets/js/cart.js"></script>
|
|
<script src="/_public/assets/js/wss.js"></script>
|
|
<link rel="apple-touch-icon" href="/_public/images/precomposed/touch-icon-iphone-precomposed.png">
|
|
<link rel="apple-touch-icon" sizes="152x152" href="/_public/images/precomposed/touch-icon-ipad-precomposed.png">
|
|
<link rel="apple-touch-icon" sizes="180x180"
|
|
href="/_public/images/precomposed/touch-icon-iphone-retina-precomposed.png">
|
|
<link rel="apple-touch-icon" sizes="167x167"
|
|
href="/_public/images/precomposed/touch-icon-ipad-retina-precomposed.png">
|
|
<link rel="apple-touch-startup-image" href="/_public/images/precomposed/touch-icon-iphone-retina-precomposed.png">
|
|
<?php if (empty($_GET['webview_mode'])): ?>
|
|
<script defer src="/_public/plugins/cookieconsent-master/src/cookieconsent.js"></script>
|
|
<script defer src="/_public/plugins/cookieconsent-master/demo/app.js"></script>
|
|
<?php endif; ?>
|
|
</head>
|
|
<body>
|
|
|
|
<?php
|
|
Ts::set([4, 22, 23, 24, 49, 53, 54, 73, 74, 87, 181, 200, 225]);
|
|
if (empty($_GET['webview_mode'])) {
|
|
Header::widget();
|
|
}
|
|
?>
|
|
<div style="width: 100%; margin: 0 auto">
|
|
<?php Content::widget(['content' => $content]); ?>
|
|
</div>
|
|
<?php
|
|
if (empty($_GET['webview_mode'])) {
|
|
Footer::widget();
|
|
}
|
|
?>
|
|
<?php if (empty($_GET['webview_mode'])): ?>
|
|
<div class="copyright">Copyright <i class="la la-copyright"></i> <?= date('Y') ?>, <?= Ts::get(225) ?></div>
|
|
<?php endif; ?>
|
|
<script>
|
|
const cart = new Cart();
|
|
cart.setCart('<?= Yii::$app->language ?>');
|
|
</script>
|
|
<script>
|
|
<?php
|
|
$msg_success = [
|
|
'bg' => 'Действието беше успешно завършено',
|
|
'en' => 'The action was successfully completed'
|
|
];
|
|
$msg_error = [
|
|
'bg' => 'Действието беше провалено',
|
|
'en' => 'The action failed'
|
|
];
|
|
|
|
$msg_warning = [
|
|
'bg' => '',
|
|
'en' => ''
|
|
];
|
|
if (isset($_SESSION['flash'])) {
|
|
if (isset($_SESSION['flash']['success'])) {
|
|
if (empty($_SESSION['flash']['msg'])) {
|
|
$_SESSION['flash']['msg'] = $msg_success[Yii::$app->language];
|
|
}
|
|
echo 'flash.success("' . $_SESSION['flash']['msg'] . '")';
|
|
} else {
|
|
if (isset($_SESSION['flash']['error'])) {
|
|
if (empty($_SESSION['flash']['msg'])) {
|
|
$_SESSION['flash']['msg'] = $msg_error[Yii::$app->language];
|
|
}
|
|
echo 'flash.error("' . $_SESSION['flash']['msg'] . '")';
|
|
} else {
|
|
if (isset($_SESSION['flash']['warning'])) {
|
|
if (empty($_SESSION['flash']['msg'])) {
|
|
$_SESSION['flash']['msg'] = $msg_warning[Yii::$app->language];
|
|
}
|
|
echo 'flash.warning("' . $_SESSION['flash']['msg'] . '")';
|
|
}
|
|
}
|
|
}
|
|
unset($_SESSION['flash']);
|
|
}
|
|
?>
|
|
<?php if(!empty($_SESSION['register_user']) || \app\services\Auth::getUser()): ?>
|
|
idleLogout();
|
|
<?php endif; ?>
|
|
</script>
|
|
</body>
|
|
</html>
|