На страницах навигация убрана наверх

This commit is contained in:
Krivchikov Dmitry 2015-12-05 16:29:08 +03:00
parent 7108c3e92a
commit 69270540ae
7 changed files with 63 additions and 63 deletions

View File

@ -227,4 +227,9 @@ class App
); );
} }
// IsControlle
public static function ic($controllerName)
{
return strtolower(substr(self::$controller, 0, strlen($controllerName))) == strtolower($controllerName);
}
} }

View File

@ -145,7 +145,7 @@ img.imageInArticle {border: solid 3px white;}
.onlyBigScreen {display: none;} .onlyBigScreen {display: none;}
body { body {
padding: 0!important; padding: 60px 0 0 0!important;
} }
div.container{ div.container{

BIN
public/img/whiteLogo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

View File

@ -1,10 +1,5 @@
<div id="pageSmoothBackground" style="background-image: url(<?= current($points)->getImg('middle') ?>);"></div> <div id="pageSmoothBackground" style="background-image: url(<?= current($points)->getImg('middle') ?>);"></div>
<div class="container"> <div class="container">
<div class="row">
<div class="middleHeader">
<a href="/"><img src="/img/logo.png" title="Карта wikipoints" /></a>
</div>
</div>
<div class="row elements"> <div class="row elements">
<div class="col-md-2"> <div class="col-md-2">
<?php foreach ($news as $item) : ?> <?php foreach ($news as $item) : ?>

View File

@ -44,10 +44,7 @@
<link rel="apple-touch-icon" sizes="120x120" href="/img/touch-icon-iphone-retina.png" /> <link rel="apple-touch-icon" sizes="120x120" href="/img/touch-icon-iphone-retina.png" />
<link rel="apple-touch-icon" sizes="152x152" href="/img/touch-icon-ipad-retina.png" /> <link rel="apple-touch-icon" sizes="152x152" href="/img/touch-icon-ipad-retina.png" />
</head> </head>
<body style="padding: 10px 25px; overflow-y: scroll;"> <body style="padding: 60px 25px 10px 25px; overflow-y: scroll;">
<div class="header">
<a href="/"><img src="/img/logo.png" title="Карта wikipoints" /></a>
</div>
<?= self::renderPartial('rightNavigation.php', array(), true) ?> <?= self::renderPartial('rightNavigation.php', array(), true) ?>
<?= isset($content) && !empty($content) ? $content : 'No content =(' ?> <?= isset($content) && !empty($content) ? $content : 'No content =(' ?>
<?= self::renderPartial('metrika.php', array(), true) ?> <?= self::renderPartial('metrika.php', array(), true) ?>

View File

@ -1,66 +1,70 @@
<?php <?php
$routes = array(); $routes = array();
$favorites = array(); $favorites = array();
if (App::$user && App::$user->id) { if (App::$user && App::$user->id) {
self::addVar('user', App::$user->id); self::addVar('user', App::$user->id);
$favorites = Favorite::model()->getAllMy(); $favorites = Favorite::model()->getAllMy();
} }
?> ?>
<div id="control" class="onlyBigScreen"> <nav class="navbar navbar-inverse navbar-fixed-top">
<div class="glyphicon _t glyphicon-info-sign boxButtonInfo" title="Информация" onclick="openBox('Info')"></div> <div class="container2">
<div class="glyphicon _c glyphicon-font" title="Лента статей" onclick="location.href='/feed/'"></div> <div class="navbar-header">
<?php if (App::$user): ?> <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<div class="glyphicon glyphicon-user _b boxButtonUser" onclick="location.href='/user/'" title="Профиль"> <span class="sr-only">Toggle navigation</span>
<?php if(Notifications::getUnreadedCount()): ?> <span class="icon-bar"></span>
<div id="notify"><?= Notifications::getUnreadedCount(); ?></div> <span class="icon-bar"></span>
<?php endif; ?> <span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="/" style="background-image: url(/img/whiteLogo.png); width: 130px;background-size: contain;background-repeat: no-repeat;background-position-x: 50%; background-position-y: 1px;"></a>
</div> </div>
<?php else: ?> <div id="navbar" class="navbar-collapse collapse">
<div class="glyphicon glyphicon-user _b" id="loginButton" onclick="$('#loginModal').modal('show');" title="Войти для добавления точки"></div> <ul class="nav navbar-nav">
<?php endif; ?> <li><a href="/">Карта</a></li>
<li class="<?= App::ic('feed')?' active ':'' ?>"><a href="/feed/">Лента</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">Инфо <span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="/article/1">О проекте</a></li>
<li><a href="#" onclick="showArticle(2);">Как пользоваться</a></li>
<li><a href="/page/points/">Список точек</a></li>
<li role="separator" class="divider"></li>
<li><a href="/?point=random">Случайная точка</a></li>
<li role="separator" class="divider"></li>
<li><a href="http://vk.com/wikipoints" target="_blank">Группа в VK</a></li>
<li><a href="https://instagram.com/wikipoints/" target="_blank">Мы в Instargam</a></li>
</ul>
</li>
<?php if (App::$user): ?> <?php if (App::$user): ?>
<div class="glyphicon glyphicon-star boxButtonFavorites" onclick="openBox('Favorites')" title="Хочу посетить"></div>
<?php endif; ?>
<a href="https://vk.com/wikipoints" target="_blank"><img src="/img/vkBigLogo.png?2" usemap="#vkbutton" style="margin-left: 285px; margin-top: 0px; position: absolute; display: none;" id="vkBigLogo" /><div class="glyphicon" style="line-height: 0;" title="WikiPoints вКонтакте"><img src="/img/b.png?v=2" style="margin-left: -5px; margin-top: 0px; height: 20px;" /></div></a> <li class="dropdown">
</div> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
<div id="box" style="position: fixed;"> <?= App::$user->nick ?>
<span id="boxClose" onclick="closeBox();">&times;</span> <?php if (Notifications::getUnreadedCount()): ?>
<div id="boxInfo"> <span style="font-weight: bolder; color: red;">
<h3>Информация</h3> [<?= Notifications::getUnreadedCount(); ?>]
<a href="/article/1">О проекте</a><br/> </span>
<a onclick="showArticle(2);" href="#">Как пользоваться</a><br/> <?php endif; ?>
<a href="/page/points">Список точек</a><br/> <span class="caret"></span>
<a href="/feed/">Статьи</a><br/> </a>
<br/> <ul class="dropdown-menu">
<a href="/?point=random">Случайная точка</a> <li><a href="/user/">Профиль</a></li>
<br/><br/><br/> <li><a href="/user/favorites/">Избранное</a></li>
<a href="http://vk.com/wikipoints" target="_blank"><img src="/img/vk-flat.png" width="24" height="24"/> Группа ВКонтакте</a> <li>
<br/><br/> <a href="/user/notifications/">Уведомления
<a href="https://instagram.com/wikipoints/" target="_blank"><img src="/img/instagram-flat.png" width="24" height="24"/> Instagram</a> <?php if (Notifications::getUnreadedCount()): ?><span style="font-weight: bolder; color: red;">[<?= Notifications::getUnreadedCount(); ?>]</span><?php endif; ?>
<br/><br/><br/> </a>
<h3>Контакты</h3> </li>
EMail: <a href="mailto:info@wikipoints.ru">info@wikipoints.ru</a><br/> <li role="separator" class="divider"></li>
VK: <a href="https://vk.com/all4dk" target="_blank">https://vk.com/all4dk</a><br/> <li><a href="/index/logout/">Выйти</a></li>
</div> </ul>
<?php if (App::$user): ?> </li>
<div id="boxFavorites">
<h3>Хочу посетить</h3>
<div id="favorites">
<?php if ($favorites): ?>
<a href="/user/favorites/"><span class="glyphicon glyphicon-star" aria-hidden="true"></span> На отдельной странице</a>
<hr/>
<?php foreach ($favorites as $favorite) : ?>
<a href="/point/<?= $favorite->pointId ?>" class="btn btn-link"><?= $favorite->point->name ?></a><br/>
<?php endforeach; ?>
<?php else: ?> <?php else: ?>
Ваши закладки пока пусты. <li><a href="#" onclick="$('#loginModal').modal('show');">Вход</a></li>
<?php endif; ?> <?php endif; ?>
</ul>
</div><!--/.nav-collapse -->
</div> </div>
</div> </nav>
<?php endif; ?>
</div>
<?= App::$user ? '' : self::renderPartial('modals/login.php', null, true) ?> <?= App::$user ? '' : self::renderPartial('modals/login.php', null, true) ?>

View File

@ -26,7 +26,6 @@ $statuses = array(
<h2> <h2>
<?php if ($imAuthor) : ?> <?php if ($imAuthor) : ?>
<a href="/article/new/" class="pull-right btn btn-success"><span class="glyphicon glyphicon-plus"></span> Новая запись</a> <a href="/article/new/" class="pull-right btn btn-success"><span class="glyphicon glyphicon-plus"></span> Новая запись</a>
<a href="/user/notifications/" class="pull-right btn btn-link">Уведомления <span class="glyphicon glyphicon-bullhorn"></span></a>
<?php endif; ?> <?php endif; ?>
Записи: Записи:
</h2> </h2>