Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stopped hardcoding the site title, site description and avatar. (fixes #2) #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions _config.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Site settings

title: Strata # Title of your site
title: Strata # Type the title of your site here
email: [email protected] # Your contant email
avatar: /images/avatar.jpg # Put your avatar in the images folder and replace avatar.jpg with the name of your file

description: Write an <strong>awesome description</strong> <br /> for your site here.</br /> Feel free to use some basic HTML <br />formating to make it even cooler.


description: > # this means to ignore newlines until "baseurl:"
Write an awesome description for your new site here. You can edit this
line in _config.yml. It will appear in your document head meta (for
Google search results) and in your feed.xml site description.
baseurl: "" # the subpath of your site, e.g. /blog/
url: "http://yourdomain.com" # the base hostname & protocol for your site

Expand Down
8 changes: 3 additions & 5 deletions _layouts/default.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html>
<head>
<title>Strata by HTML5 UP</title>
<title>{{ site.title }}</title>
Copy link
Contributor

Choose a reason for hiding this comment

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

This should be page.title by default and fall back to site.title so the page titles aren't the same on all pages

<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="description" content="" />
<meta name="keywords" content="" />
Expand All @@ -21,10 +21,8 @@
<body id="top">

<header id="header">
<a href="#" class="image avatar"><img src="/images/avatar.jpg" alt="" /></a>
<h1><strong>I am <a href="/">Strata</a></strong>, a super simple<br />
responsive site template freebie<br />
crafted by <a href="http://html5up.net">HTML5 UP</a>.</h1>
<a href="{{ site.baseurl }}" class="image avatar"><img src="{{ site.avatar }}" alt="" /></a>
<h1>{{ site.description }}</h1>
</header>


Expand Down
10 changes: 5 additions & 5 deletions _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@
<div id="main">
<article>
<header class="major">
<h2 class="post-title">{{ page.title }}</h2>
<h2 class="post-title">{{ site.title }}</h2>
<p class="post-meta">{{ page.date | date: "%b %-d, %Y" }}{% if page.author %} • {{ page.author }}{% endif %}{% if page.meta %} • {{ page.meta }}{% endif %}</p>
</header>

<section>
{{ content }}
</section>

<footer>
<div class="row">
{% if page.previous %}

<article class="{% cycle '6u', '6u$' %} 12u(small) excerpt">
<header>
<h2><a href="{{ page.previous.url }}">{{ page.previous.title }}</a></h2>
Expand All @@ -30,9 +30,9 @@ <h2><a href="{{ page.previous.url }}">{{ page.previous.title }}</a></h2>
</footer>
</article>
{% endif %}

{% if page.next %}

<article class="{% cycle '6u', '6u$' %} 12u(small) excerpt f-right">
<header>
<h2><a href="{{ page.next.url }}">{{ page.next.title }}</a></h2>
Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<section>
{% for post in site.posts limit:1 %}
<header class="major">
<h2>{{ post.title }}</h2>
<h2>{{ post.title | site.title }}</h2>
<p class="post-meta">{{ post.date | date: "%b %-d, %Y" }}{% if post.author %} • {{ post.author }}{% endif %}{% if page.meta %} • {{ page.meta }}{% endif %}</p>
</header>

Expand Down