You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

263 lines
9.2 KiB

<?php
session_start();
include "php/config.php";
$active = "class = 'active'";
$included_files = get_included_files(); // this is to get the file that is currently including the menu.php in its include_once
?>
<!DOCTYPE html>
<html lang="<?php echo $_SESSION['lang']?>">
<head>
<meta charset="utf-8">
<meta name="description" content="Laboratorio Ravettino">
<meta name="keywords" content="Ravettino,Multibioticos,Gingisona B, Buk, Mentholatum, Broncopulmin, Laboratorio">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/png" sizes="32x32" href="imagenes/favicon-32x32.png">
<link href="css/normalize.css" rel="stylesheet" type="text/css">
<link href="css/estilos.css" rel="stylesheet" type="text/css">
<link href="css/timeline.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.8.1/css/all.css">
<script type="text/javascript" src="js/loading.js"></script>
<link href="css/form.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.3.3/dist/leaflet.css" integrity="sha512-Rksm5RenBEKSKFjgI3a41vrjkw4EVPlJ3+OiI65vTjIdo9brlAacEuKOiQ5OFh7cOI1bkDwLqdLw3Zg0cRJAAQ==" crossorigin="" />
<!-- Link to Google's jQuery CDN -->
<script src="//code.jquery.com/jquery-3.3.1.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>
<!-- Make sure you put this AFTER Leaflet's CSS -->
<script src="https://unpkg.com/leaflet@1.3.3/dist/leaflet.js" integrity="sha512-tAGcCfR4Sc5ZP5ZoVz0quoZDYX5aCtEm/eu1KhSLj2c9eFrylXZknQYmxUssFaVJKvvc0dJQixhGjG2yXWiV9Q==" crossorigin=""></script>
<script src="js/Leaflet.Sleep.js"></script>
<?php
foreach($included_files as $filename) {
switch(1) {
case (preg_match('/index/', $filename)):
if ($_SESSION['lang'] == 'en') {
echo '<title>Ravettino Labs | Home</title>';
} else if ($_SESSION['lang'] == 'es'){
echo '<title>Laboratorio Ravettino | Inicio</title>';
} else if ($_SESSION['lang'] == 'por'){
echo '<title>Laboratório Ravettino | Home</title>';
}
break;
case (preg_match('/nosotros/', $filename)):
if ($_SESSION['lang'] == 'en') {
echo '<title>Ravettino Labs | Meet Us</title>';
} else if ($_SESSION['lang'] == 'es'){
echo '<title>Laboratorio Ravettino | Nosotros</title>';
} else if ($_SESSION['lang'] == 'por'){
echo '<title>Laboratório Ravettino | Sobre nós</title>';
}
break;
case (preg_match('/clientes/', $filename)):
if ($_SESSION['lang'] == 'en') {
echo '<title>Ravettino Labs | Clients</title>';
} else if ($_SESSION['lang'] == 'es'){
echo '<title>Laboratorio Ravettino | Clientes</title>';
} else if ($_SESSION['lang'] == 'por'){
echo '<title>Laboratório Ravettino | Clientes</title>';
}
break;
case (preg_match('/servicios/', $filename)):
if ($_SESSION['lang'] == 'en') {
echo '<title>Ravettino Labs | Services</title>';
} else if ($_SESSION['lang'] == 'es'){
echo '<title>Laboratorio Ravettino | Servicios</title>';
} else if ($_SESSION['lang'] == 'por'){
echo '<title>Laboratório Ravettino | Serviços</title>';
}
break;
case (preg_match('/contacto/', $filename)):
if ($_SESSION['lang'] == 'en') {
echo '<title>Ravettino Labs | Contact Us</title>';
} else if ($_SESSION['lang'] == 'es'){
echo '<title>Laboratorio Ravettino | Contacto</title>';
} else if ($_SESSION['lang'] == 'por'){
echo '<title>Laboratório Ravettino | Contato</title>';
}
break;
}
}?>
<?php if ($_SESSION['theme'] == 'dark') { ?>
<style>
#overlay {
background-color: var(--dark-bg);
color: var(--dark-txt);
}
h1 {
color: var(--dark-txt);
}
#timeline .carta-timeline .contenido-timeline {
border: 1px solid var(--color);
}
.menu-centrar{
background: var(--dark-bg);
}
.phone a, .email a {
color: var(--dark-txt);
}
#envoltura-vinculos .content {
background: var(--mid-dark-txt);
}
#loading {
background: var(--dark-bg);
}
.modalclientes-content {
background: var(--dark-bg);
}
.modal-content {
background: var(--dark-bg);
}
.modal-contacto .envoltura-modal {
background: var(--dark-bg);
}
.modal-contacto .envoltura-modal p{
color: var(--dark-txt);
}
</style><?php }?>
</head>
<!-- Animacion de carga -->
<div id="loading">
<img src="imagenes/loading_spinner.gif" alt="Loading..." id="loading-image">
</div>
<!-- Menu Lateral -->
<div id="menu-lateral" class="nav-lateral">
<a class="btn-cerrar">&times;</a>
<div class="menu-centrar">
<div class="mode">
<?php if($_SESSION['theme'] == 'light') { ?>
<a href="?theme=dark"><i class="far fa-moon dark"></i></a>
<?} else if($_SESSION['theme'] == 'dark') { ?>
<a href="?theme=light"><i class="far fa-sun light"></i></a>
<?} ?>
</div>
<ul class="navlateral">
<a href="index"
<?php
foreach($included_files as $filename) {
if (preg_match('/\bindex\b/', $filename)) {
echo $active;
}
}
?> ><?php echo $lang['menu1'] ?></a>
<a href="nosotros"
<?php
foreach($included_files as $filename) {
if (preg_match('/\bnosotros\b/', $filename)) {
echo $active;
}
}
?> ><?php echo $lang['menu2'] ?></a>
<a href="clientes"
<?php
foreach($included_files as $filename) {
if (preg_match('/\bclientes\b/', $filename)) {
echo $active;
}
}
?>
><?php echo $lang['menu3'] ?></a>
<a href="servicios"
<?php
foreach($included_files as $filename) {
if (preg_match('/\bservicios\b/', $filename)) {
echo $active;
}
}
?>
><?php echo $lang['menu4'] ?></a>
<a href="contacto"
<?php
foreach($included_files as $filename) {
if (preg_match('/\bcontacto\b/', $filename)) {
echo $active;
}
}
?>
><?php echo $lang['menu5'] ?></a>
<div class="envoltura-dropdown">
<div class="lang-dropdown">
<?php echo $lang['lang'] . ': ' .$_SESSION['lang'] ?>
<i class="fas fa-caret-down"></i>
</div>
<ul>
<a href="?lang=es"><?php echo $lang['es'] ?></a>
<a href="?lang=en"><?php echo $lang['en'] ?></a>
<a href="?lang=por"><?php echo $lang['por'] ?></a>
</ul>
</div>
</ul>
</div>
</div>
<div id="overlay">
<nav>
<nav class="navbar" id="nav-bar">
<span class="abrir-lateral">
<a>
<span class="fas fa-bars"></span>
</a>
</span>
<a href="index" class="navbar-imagen"><img src="logo/logo.png" alt="Ravettino Logo" id="navbar-imagen"></a>
<ul class="navbar-nav">
<div class="mode">
<?php if($_SESSION['theme'] == 'light') { ?>
<a href="?theme=dark"><i class="far fa-moon dark"></i></a>
<?} else if($_SESSION['theme'] == 'dark') { ?>
<a href="?theme=light"><i class="far fa-sun light"></i></a>
<?} ?>
</div>
<div class="envoltura-dropdown">
<span class="lang-dropdown">
<?php echo $lang['lang'] . ': ' .$_SESSION['lang'] ?>
<i class="fas fa-caret-down"></i>
</span>
<ul>
<a href="?lang=es"><?php echo $lang['es'] ?></a>
<a href="?lang=en"><?php echo $lang['en'] ?></a>
<a href="?lang=por"><?php echo $lang['por'] ?></a>
</ul>
</div>
<a href="contacto" <?php
foreach($included_files as $filename) {
if (preg_match('/\bcontacto\b/', $filename)) {
echo $active;
}
}
?>>
<li><?php echo $lang['menu5'] ?></li>
</a>
<a href="servicios" <?php
foreach($included_files as $filename) {
if (preg_match('/\bservicios\b/', $filename)) {
echo $active;
}
}
?>>
<li><?php echo $lang['menu4'] ?></li>
</a>
<a href="clientes" <?php
foreach($included_files as $filename) {
if (preg_match('/\bclientes\b/', $filename)) {
echo $active;
}
}
?>>
<li><?php echo $lang['menu3'] ?></li>
</a>
<a href="nosotros" <?php
foreach($included_files as $filename) {
if (preg_match('/\bnosotros\b/', $filename)) {
echo $active;
}
}
?>>
<li><?php echo $lang['menu2'] ?></li>
</a>
</ul>
</nav>
</nav>
</div>
?>