Skip to content
This repository has been archived by the owner on May 1, 2019. It is now read-only.

Enhancement: Streamline layouts and fix-up content #397

Merged
merged 11 commits into from
Feb 18, 2015
101 changes: 49 additions & 52 deletions module/Application/view/layout/layout-small-header.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -2,53 +2,53 @@

<html lang="en">
<head>
<?php echo $this->headTitle('ZF2 Modules')->setSeparator(' - ')->setAutoEscape(false) ?>
<?php $this->headTitle('ZF2 Modules')->setSeparator(' - ')->setAutoEscape(false); ?>
<?php echo $this->headTitle(); ?>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I liked the previous approach better (easier to read, imo)


<?php
echo $this->headMeta()
->appendName('viewport', 'width=device-width, initial-scale=1.0')
->setCharset('UTF-8')
?>
<?php $this->headMeta()->appendName('viewport', 'width=device-width, initial-scale=1.0'); ?>
<?php $this->headMeta()->setCharset('UTF-8'); ?>
<?php echo $this->headMeta(); ?>

<?php
echo $this->headLink(['rel' => 'shortcut icon', 'href' => $this->basePath() . '/favicon.ico'])
->appendStylesheet($this->basePath() . '/css/bootstrap.min.css')
->appendStylesheet($this->basePath() . '/css/style.css')
->appendStylesheet($this->basePath() . '/css/slide.css')
->appendAlternate($this->url('feed'), 'application/rss+xml', 'RSS Feed for ZF2 Modules')
?>
<?php $this->headLink(['rel' => 'shortcut icon', 'href' => $this->basePath() . '/favicon.ico']); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/bootstrap.min.css'); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/style.css'); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/slide.css'); ?>
<?php $this->headLink()->appendAlternate($this->url('feed'), 'application/rss+xml', 'RSS Feed for ZF2 Modules'); ?>
<?php echo $this->headLink(); ?>
</head>
<body>
<a href="https://github.com/zendframework/modules.zendframework.com"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub"></a>

<a href="https://github.com/zendframework/modules.zendframework.com">
<img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub">
</a>
<div id="toppanel">
<div class="tab">
<ul class="login">
<li class="left">&nbsp;</li>
<li><a href="<?php echo $this->url('home'); ?>">Home</a></li>
<?php
$userDisplayName = $this->zfcUserDisplayName();
if ($userDisplayName): ?>
<li class="sep">|</li>
<li class="user-info">
<?php /* @var User\Entity\User $identity */ ?>
<?php $identity = $this->zfcUserIdentity(); ?>
<div class="gravatar-container"><a class="login" href="<?php
echo $this->url('zfcuser');
?>" title="My profile">
<img src="<?php
echo $this->escapeHtmlAttr($identity->getPhotoUrl());
?>" alt="<?php echo $this->escapeHtmlAttr($this->zfcUserDisplayName());
?>" style="width:23px;height:23px;" />
</a></div><a class="login" href="<?php echo $this->url('zfcuser') ?>" title="My profile"> Hello <?php echo $this->escapeHtml(ucfirst($userDisplayName)); ?></a>
</li>
<li class="sep">|</li>
<li ><a href="<?php echo $this->url('zfcuser/logout'); ?>">Logout</a></li>
<?php else: ?>
<li id="toggle">
<a class="login" href="<?php echo $this->url('scn-social-auth-user/login/provider', ['provider' => 'github']); ?>">GitHub Login</a>
</li>
<?php endif; ?>
<li>
<a href="<?php echo $this->url('home'); ?>">Home</a>
</li>
<?php $userDisplayName = $this->zfcUserDisplayName(); ?>
<?php if ($userDisplayName): ?>
<li class="sep">|</li>
<li class="user-info">
<?php /* @var User\Entity\User $identity */ ?>
<?php $identity = $this->zfcUserIdentity(); ?>
<div class="gravatar-container">
<a class="login" href="<?php echo $this->url('zfcuser'); ?>" title="My profile">
<img src="<?php echo $this->escapeHtmlAttr($identity->getPhotoUrl()); ?>" alt="<?php echo $this->escapeHtmlAttr($this->zfcUserDisplayName()); ?>" style="width:23px;height:23px;">
</a>
</div>
<a class="login" href="<?php echo $this->url('zfcuser'); ?>" title="My profile"> Hello <?php echo $this->escapeHtml(ucfirst($userDisplayName)); ?></a>
</li>
<li class="sep">|</li>
<li>
<a href="<?php echo $this->url('zfcuser/logout'); ?>">Logout</a>
</li>
<?php else: ?>
<li id="toggle">
<a class="login" href="<?php echo $this->url('scn-social-auth-user/login/provider', ['provider' => 'github']); ?>">GitHub Login</a>
</li>
<?php endif; ?>
<li class="right">&nbsp;</li>
</ul>
</div>
Expand All @@ -59,31 +59,28 @@
<div class="row">
<div class="col-md-8">
<a href="<?php echo $this->url('home'); ?>" style="text-decoration:none">
<img src="<?php echo $this->basePath('/img/zend-logo_small.png'); ?>" alt="ZF Modules"/>
<p class="zf-green">Modules</p>
<img src="<?php echo $this->basePath('/img/zend-logo_small.png'); ?>" alt="ZF Modules">
<p class="zf-green">
Modules
</p>
</a>
</div>
<div class="col-md-4">

</div>
</div>
</div>
</div>


<div class="container main-content">
<div class="container-fluid">
<?php echo $this->content; ?>
</div
</div>
</div>
<hr style="clear:both" />

<hr style="clear:both">

<?php echo $this->partial('layout/footer'); ?>

<?php
echo $this->inlineScript()
->prependFile($this->basePath() . '/js/bootstrap.min.js')
->prependFile($this->basePath() . '/js/jquery-1.11.2.min.js')
?>
<?php $this->inlineScript()->prependFile($this->basePath() . '/js/bootstrap.min.js'); ?>
<?php $this->inlineScript()->prependFile($this->basePath() . '/js/jquery-1.11.2.min.js'); ?>
<?php echo $this->inlineScript(); ?>
</body>
</html>
109 changes: 55 additions & 54 deletions module/Application/view/layout/layout.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -2,54 +2,54 @@

<html lang="en">
<head>
<?php echo $this->headTitle('ZF2 Modules')->setSeparator(' - ')->setAutoEscape(false) ?>
<?php $this->headTitle('ZF2 Modules')->setSeparator(' - ')->setAutoEscape(false); ?>
<?php echo $this->headTitle(); ?>

<?php
echo $this->headMeta()
->appendName('viewport', 'width=device-width, initial-scale=1.0')
->setCharset('UTF-8')
?>

<?php
echo $this->headLink(['rel' => 'shortcut icon', 'href' => $this->basePath() . '/favicon.ico'])
->appendStylesheet($this->basePath() . '/css/bootstrap.min.css')
->appendStylesheet($this->basePath() . '/css/style.css')
->appendStylesheet($this->basePath() . '/css/slide.css')
->appendStylesheet($this->basePath() . '/css/jquery.livesearch.css')
->appendAlternate($this->url('feed'), 'application/rss+xml', 'RSS Feed for ZF2 Modules')
?>
<?php $this->headMeta()->appendName('viewport', 'width=device-width, initial-scale=1.0'); ?>
<?php $this->headMeta()->setCharset('UTF-8'); ?>
<?php echo $this->headMeta(); ?>

<?php $this->headLink(['rel' => 'shortcut icon', 'href' => $this->basePath() . '/favicon.ico']); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/bootstrap.min.css'); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/style.css'); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/slide.css'); ?>
<?php $this->headLink()->appendStylesheet($this->basePath() . '/css/jquery.livesearch.css'); ?>
<?php $this->headLink()->appendAlternate($this->url('feed'), 'application/rss+xml', 'RSS Feed for ZF2 Modules'); ?>
<?php echo $this->headLink(); ?>
</head>
<body>
<a href="https://github.com/zendframework/modules.zendframework.com"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub"></a>

<a href="https://github.com/zendframework/modules.zendframework.com">
<img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_green_007200.png" alt="Fork me on GitHub">
</a>
<div id="toppanel">
<div class="tab">
<ul class="login">
<li class="left">&nbsp;</li>
<li><a href="<?php echo $this->url('home') ?>">Home</a></li>
<?php
$userDisplayName = $this->zfcUserDisplayName();
if ($userDisplayName):
?>
<li class="sep">|</li>
<li class="user-info">
<?php /* @var User\Entity\User $identity */ ?>
<?php $identity = $this->zfcUserIdentity(); ?>
<div class="gravatar-container"><a class="login" href="<?php echo $this->url('zfcuser') ?>" title="My profile">
<img src="<?php
echo $this->escapeHtmlAttr($identity->getPhotoUrl());
?>" alt="<?php echo $this->escapeHtmlAttr($this->zfcUserDisplayName());
?>" style="width:23px;height:23px;" />
</a></div><a class="login" href="<?php echo $this->url('zfcuser') ?>" title="My profile"> Hello <?php echo $this->escapeHtml(ucfirst($userDisplayName)) ?></a>
</li>
<li class="sep">|</li>
<li ><a href="<?php echo $this->url('zfcuser/logout') ?>">Logout</a></li>
<?php else: ?>
<li id="toggle">
<a class="login" href="<?php echo $this->url('scn-social-auth-user/login/provider', ['provider' => 'github']) ?>">GitHub Login</a>
</li>
<?php endif; ?>
<li>
<a href="<?php echo $this->url('home'); ?>">Home</a>
</li>
<?php $userDisplayName = $this->zfcUserDisplayName(); ?>
<?php if ($userDisplayName): ?>
<li class="sep">|</li>
<li class="user-info">
<?php /* @var User\Entity\User $identity */ ?>
<?php $identity = $this->zfcUserIdentity(); ?>
<div class="gravatar-container">
<a class="login" href="<?php echo $this->url('zfcuser'); ?>" title="My profile">
<img src="<?php echo $this->escapeHtmlAttr($identity->getPhotoUrl()); ?>" alt="<?php echo $this->escapeHtmlAttr($this->zfcUserDisplayName()); ?>" style="width:23px;height:23px;">
</a>
</div>
<a class="login" href="<?php echo $this->url('zfcuser'); ?>" title="My profile"> Hello <?php echo $this->escapeHtml(ucfirst($userDisplayName)); ?></a>
</li>
<li class="sep">|</li>
<li>
<a href="<?php echo $this->url('zfcuser/logout'); ?>">Logout</a>
</li>
<?php else: ?>
<li id="toggle">
<a class="login" href="<?php echo $this->url('scn-social-auth-user/login/provider', ['provider' => 'github']); ?>">GitHub Login</a>
</li>
<?php endif; ?>
<li class="right">&nbsp;</li>
</ul>
</div>
Expand All @@ -62,40 +62,41 @@
<h1 class="zf-green">
<strong>Welcome to the ZF2 Modules Site</strong>
</h1>
<h3 class="text-muted">Find one of <strong><?php echo $this->totalModules() ?></strong> modules that fits your needs.</h3>
<h3 class="text-muted">Find one of <strong><?php echo $this->totalModules(); ?></strong> modules that fits your needs.</h3>
<div>
<p>
This website is a work-in-progress. In the future you will be able to use this website to browse, search, rate, and comment on all of the great modules the Zend Framework community has to offer.
If you are interested in helping with this project, simply fork the code on
<a class="zf-green" href="https://github.com/zendframework/modules.zendframework.com" target="_blank">GitHub</a>
and get started!
</p>
<hr />
<p>
If you are interested in helping with this project, simply fork the code on <a class="zf-green" href="https://github.com/zendframework/modules.zendframework.com">GITHUB</a> and get started!
Additionally, join us in #zftalk.modules on Freenode and ask how you can help! Grab latest modules using <a class="zf-green" href="<?php echo $this->url('feed') ?>">RSS Feed</a>.
Additionally, join us in #zftalk.modules on Freenode and ask how you can help!
</p>
<p>
Grab latest modules using <a class="zf-green" href="<?php echo $this->url('feed') ?>">RSS Feed</a>.
</p>
</div>
</div>
<div class="col-md-4 hidden-xs hidden-sm">
<img class="attentionimage pull-right" src="<?php echo $this->basePath('/img/rsz_logo.png') ?>" alt="ZF Modules"/>
<img class="attentionimage pull-right" src="<?php echo $this->basePath('/img/rsz_logo.png'); ?>" alt="ZF Modules">
</div>
</div>
</div>
</div>


<div class="container main-content">
<div class="container-fluid">
<?php echo $this->content; ?>
</div>
</div>
<hr style="clear:both" />

<hr style="clear:both">

<?php echo $this->partial('layout/footer'); ?>

<?php
echo $this->inlineScript()
->prependFile($this->basePath() . '/js/jquery.livesearch.js')
->prependFile($this->basePath() . '/js/bootstrap.min.js')
->prependFile($this->basePath() . '/js/jquery-1.11.2.min.js')
?>
<?php $this->inlineScript()->prependFile($this->basePath() . '/js/jquery.livesearch.js'); ?>
<?php $this->inlineScript()->prependFile($this->basePath() . '/js/bootstrap.min.js'); ?>
<?php $this->inlineScript()->prependFile($this->basePath() . '/js/jquery-1.11.2.min.js'); ?>
<?php echo $this->inlineScript(); ?>
</body>
</html>