mirror of
https://github.com/danpros/htmly.git
synced 2026-04-21 13:06:22 +05:30
Improve theme
Improve theme
This commit is contained in:
parent
3fb6c4bdb3
commit
b62f013588
10 changed files with 22 additions and 19 deletions
|
|
@ -133,7 +133,7 @@ get('/:year/:month/:name', function($year, $month, $name){
|
|||
render('post',array(
|
||||
'head_contents' => head_contents($current->title .' - ' . blog_title(), $description = get_description($current->body), $current->url),
|
||||
'p' => $current,
|
||||
'authorinfo' => '<div class="author-info"><h4>by <strong>' . $bio->title . '</strong></h4>' . $bio->body . '</div>',
|
||||
'authorinfo' => authorinfo($bio->title, $bio->body),
|
||||
'bodyclass' => 'inpost',
|
||||
'breadcrumb' => '<span typeof="v:Breadcrumb"><a property="v:title" rel="v:url" href="' . site_url() . '">' .config('breadcrumb.home'). '</a></span> » '. $current->tagb . ' » ' . $current->title,
|
||||
'prev' => has_prev($prev),
|
||||
|
|
|
|||
|
|
@ -1346,6 +1346,13 @@ function blog_copyright() {
|
|||
return config('blog.copyright');
|
||||
}
|
||||
|
||||
// Return author info
|
||||
function authorinfo($title=null, $body=null) {
|
||||
if (config('author.info') == 'true') {
|
||||
return '<div class="author-info"><h4>by <strong>' . $title . '</strong></h4>' . $body . '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
function head_contents($title, $description, $canonical) {
|
||||
$output = '';
|
||||
$title = '<title>' . $title . '</title>';
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" user-scalable="no" />
|
||||
<title>Search results not found! - <?php echo config('blog.title') ?></title>
|
||||
<title>Search results not found! - <?php echo blog_title() ?></title>
|
||||
<link href="<?php echo site_url() ?>themes/clean/css/style.css" rel="stylesheet" />
|
||||
<!-- Include the Open Sans font -->
|
||||
<link href="http://fonts.googleapis.com/css?family=Open+Sans+Condensed:700&subset=latin,cyrillic-ext" rel="stylesheet" />
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" user-scalable="no" />
|
||||
<title>404 Not Found - <?php echo config('blog.title') ?></title>
|
||||
<title>404 Not Found - <?php echo blog_title() ?></title>
|
||||
<link href="<?php echo site_url() ?>themes/clean/css/style.css" rel="stylesheet" />
|
||||
<!-- Include the Open Sans font -->
|
||||
<link href="http://fonts.googleapis.com/css?family=Open+Sans+Condensed:700&subset=latin,cyrillic-ext" rel="stylesheet" />
|
||||
|
|
|
|||
|
|
@ -11,13 +11,13 @@
|
|||
</head>
|
||||
<body class="<?php echo $bodyclass; ?>" itemscope="itemscope" itemtype="http://schema.org/Blog">
|
||||
<div class="hide">
|
||||
<meta content="<?php echo config('blog.title') ?>" itemprop="name"/>
|
||||
<meta content="<?php echo config('blog.description')?>" itemprop="description"/>
|
||||
<meta content="<?php echo blog_title() ?>" itemprop="name"/>
|
||||
<meta content="<?php echo blog_description() ?>" itemprop="description"/>
|
||||
</div>
|
||||
<?php if(login()) { toolbar();} ?>
|
||||
<aside>
|
||||
<h1 class="blog-title"><a href="<?php echo site_url() ?>"><?php echo config('blog.title') ?></a></h1>
|
||||
<div class="blog-tagline"><p><?php echo config('blog.tagline')?></p></div>
|
||||
<h1 class="blog-title"><a href="<?php echo site_url() ?>"><?php echo blog_title() ?></a></h1>
|
||||
<div class="blog-tagline"><p><?php echo blog_tagline() ?></p></div>
|
||||
<div class="search">
|
||||
<?php echo search() ?>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -16,9 +16,7 @@
|
|||
</div>
|
||||
<div class="separator">→</div>
|
||||
<div class="share-box">
|
||||
<?php if (config('author.info') == 'true'):?>
|
||||
<?php echo $authorinfo ?>
|
||||
<?php endif;?>
|
||||
<div class="share">
|
||||
<h4>Share this post</h4>
|
||||
<a class="twitter" target="_blank" href="https://twitter.com/share?url=<?php echo $p->url ?>&text=<?php echo $p->title?>">Twitter</a>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" user-scalable="no" />
|
||||
<title>Search results not found! - <?php echo config('blog.title') ?></title>
|
||||
<title>Search results not found! - <?php echo blog_title() ?></title>
|
||||
<link href="<?php echo site_url() ?>themes/default/css/style.css" rel="stylesheet" />
|
||||
<!-- Include the Open Sans font -->
|
||||
<link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" user-scalable="no" />
|
||||
<title>404 Not Found - <?php echo config('blog.title') ?></title>
|
||||
<title>404 Not Found - <?php echo blog_title() ?></title>
|
||||
<link href="<?php echo site_url() ?>themes/default/css/style.css" rel="stylesheet" />
|
||||
<!-- Include the Open Sans font -->
|
||||
<link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>
|
||||
|
|
|
|||
|
|
@ -11,8 +11,8 @@
|
|||
</head>
|
||||
<body class="<?php echo $bodyclass; ?>" itemscope="itemscope" itemtype="http://schema.org/Blog">
|
||||
<div class="hide">
|
||||
<meta content="<?php echo config('blog.title') ?>" itemprop="name"/>
|
||||
<meta content="<?php echo config('blog.description')?>" itemprop="description"/>
|
||||
<meta content="<?php echo blog_title() ?>" itemprop="name"/>
|
||||
<meta content="<?php echo blog_description() ?>" itemprop="description"/>
|
||||
</div>
|
||||
<?php if(login()) { toolbar();} ?>
|
||||
<div id="outer-wrapper">
|
||||
|
|
@ -28,8 +28,8 @@
|
|||
<div class="container">
|
||||
<header id="header">
|
||||
<section id="branding">
|
||||
<h1 class="blog-title"><a href="<?php echo site_url() ?>"><?php echo config('blog.title') ?></a></h1>
|
||||
<div class="blog-tagline"><p><?php echo config('blog.tagline')?></p></div>
|
||||
<h1 class="blog-title"><a href="<?php echo site_url() ?>"><?php echo blog_title() ?></a></h1>
|
||||
<div class="blog-tagline"><p><?php echo blog_tagline() ?></p></div>
|
||||
</section>
|
||||
</header>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -16,9 +16,7 @@
|
|||
</div>
|
||||
<div class="separator">→</div>
|
||||
<div class="share-box">
|
||||
<?php if (config('author.info') == 'true'):?>
|
||||
<?php echo $authorinfo ?>
|
||||
<?php endif;?>
|
||||
<div class="share">
|
||||
<h4>Share this post</h4>
|
||||
<a class="twitter" target="_blank" href="https://twitter.com/share?url=<?php echo $p->url ?>&text=<?php echo $p->title?>">Twitter</a>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue