<?php
require './includes/inicio.php';
$i = (isset($_GET['i'])) ? $_GET['i'] : 'cms-home';

$cms = $GLOBALS['cms'];
$baseUrl = Util::baseUrl() . $cms;
$baseDir = Util::baseDir() . $cms;
require $baseDir . 'includes/verificaSessao.php';
?>
<!doctype html>
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
<!--[if IE 7]>    <html class="no-js lt-ie9 lt-ie8" lang="en"> <![endif]-->
<!--[if IE 8]>    <html class="no-js lt-ie9" lang="en"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" style="overflow-x:hidden;"> <!--<![endif]-->
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title>Yak || Cappen.com</title>
    <meta name="description" content="">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/neo/stylesheet.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/helvetica/stylesheet.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/js/libs/jquery-ui/themes/yak/jquery.ui.all.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/ui.multiselect.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/application.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/main.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/font-awesome.min.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/js/Jcrop/css/Jcrop.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/DateTimePicker.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/chosen.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/iziToast.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/remodal.css">
    <link rel="stylesheet" href="<?= $baseUrl; ?>public/css/select2.min.css">
    <script type="text/javascript" src="<?= $baseUrl; ?>public/js/jquery-1.7.1.min.js"></script>
    <!--[if lt IE 9]>
        <link rel="stylesheet" type="text/css" href="<?= $baseUrl; ?>public/css/DateTimePicker-ltie9.css" />
        <script type="text/javascript" src="<?= $baseUrl; ?>public/js/DateTimePicker-ltie9.js"></script>
    <![endif]-->
</head>

<body>
  <!--[if lt IE 7]><p class=chromeframe>Your browser is <em>ancient!</em> <a href="http://browsehappy.com/">Upgrade to a different browser</a> or <a href="http://www.google.com/chromeframe/?redirect=true">install Google Chrome Frame</a> to experience this site.</p><![endif]-->
  <header>
        <div id="infoCliente">
            <div class="contentHeader clearfix">
                <p class="left"><img src="<?= $baseUrl; ?>public/img/logomini.png" alt="YAK" /> | GESTOR DE CONTEÚDO ONLINE | <a href="<?= Util::$siteUrl; ?>" target="_blank" title="Link para o site"><?= Util::$siteNome; ?></a></p>
                <a href="<?= $baseUrl; ?>login/logout.php" class="logout right">fazer <strong>logout</strong></a>
            </div>
        </div>
        <div class="contentHeader clearfix">
            <h1 class="logo"><a href="<?= $baseUrl; ?>"><img src="<?= $baseUrl; ?>public/img/logo.png" alt="YAK" /> GESTOR<br />DE <strong>CONTEÚDO</strong></a></h1>
            <div id="busca">
              <form name="formBusca" id="formBusca" class="form" method="post" action="">
                  <input type="text" class="clearInput" name="buscar" id="buscar" placeholder="Fazer Pesquisa" value="<?= (!empty($_POST['buscar'])) ? $_POST['buscar'] : ''; ?>" />
                  <input type="submit" value="" name="ok" id="ok" onclick="javascript:document.form_busca.submit();" />
              </form>
            </div>
        </div>
        <div id="saudacao">
            <div class="contentHeader clearfix">
                <p class="left">Seja bem vindo(a) ao YAK, <span><?= $_SESSION['sesCMSNome']; ?></span>.</p>
                <nav class="right">
                    <a href="<?= $baseUrl; ?>?i=cms-user-editar"><span class="seta"></span> editar conta</a>

                    <?php $ac = Acesso::check('cms-user'); ?>

                    <?php if ($ac->inserir()) : ?>
                      <a href="<?= $baseUrl; ?>?i=cms-user-inserir"><span class="seta"></span> cadastrar novo usuário</a>
                    <?php endif; ?>
                </nav>
            </div>
        </div>
  </header>
