more flexible header configuration

This commit is contained in:
Gaspard Jankowiak 2013-03-08 13:14:26 +01:00
parent 34fa3d58f2
commit 4a7b83ae3b
4 changed files with 34 additions and 5 deletions

View file

@ -9,3 +9,8 @@ safe: true
pygments: true pygments: true
style: light style: light
title: 'Gaspard Jankowiak · Ceremade · Université Paris Dauphine'
header-title: 'Page personnelle de Gaspard Jankowiak'
header-subtitle: 'Thésard au Ceremade — Université Paris Dauphine'
header-homelink: '/'

View file

@ -2,7 +2,13 @@
<html> <html>
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<title>{{ page:title }}</title> <title>
{% if page:title %}
{{ page:title }}
{% else %}
{{ site:title }}
{% endif %}
</title>
<link rel="icon" href="/images/favicon.png"> <link rel="icon" href="/images/favicon.png">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script type="text/x-mathjax-config"> <script type="text/x-mathjax-config">
@ -32,8 +38,25 @@
<section> <section>
<div id="title"> <div id="title">
<h1><a href="/">Page personnelle de Gaspard Jankowiak</a></h1> {% if page:header-homelink %}
<p>Thésard au Ceremade — Université Paris-Dauphine</p> {% assign homelink = page:header-homelink %}
{% else %}
{% assign homelink = site:header-homelink %}
{% endif %}
<h1><a href="{{ homelink }}">
{% if page:header-title %}
{{ page:header-title }}
{% else %}
{{ site:header-title }}
{% endif %}
</a></h1>
<p>
{% if page:header-subtitle %}
{{ page:header-subtitle }}
{% else %}
{{ site:header-subtitle }}
{% endif %}
</p>
<hr> <hr>
</div> </div>

View file

@ -1,6 +1,8 @@
--- ---
title: Gaspard Jankowiak · Ceremade · Université Paris Dauphine
layout: default layout: default
header-title: Gaspard Jankowiak's homepage
header-subtitle: PhD student at Ceremade &mdash; Université Paris Dauphine
header-homelink: /en
--- ---
[FR](/)\|EN [FR](/)\|EN

View file

@ -1,5 +1,4 @@
--- ---
title: Gaspard Jankowiak · Ceremade · Université Paris Dauphine
layout: default layout: default
--- ---