- Changed header_wp.html and header.html so that they will also work on the homepage (if the current page is the homepage then use the site bigimg/title/subtitle, otherwise use the page bigimg/title/subtitle; need to add them to the scratchpad so that they are accessible outside the scope of the if/else statement). - Change index.html to use the header_wp.html partial instead of duplicating the same code
22 lines
No EOL
815 B
HTML
22 lines
No EOL
815 B
HTML
{{ $subtitle := $.Scratch.Get "subtitle" }}
|
|
|
|
<div class="container">
|
|
<div class="row">
|
|
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
|
|
<div class="{{ .Type }}-heading">
|
|
<h1>{{ with $.Scratch.Get "title" }}{{.}}{{ else }}<br/>{{ end }}</h1>
|
|
{{ if $subtitle }}
|
|
{{ if eq .Type "page" }}
|
|
<hr class="small">
|
|
<span class="{{ .Type }}-subheading">{{ $subtitle }}</span>
|
|
{{ else }}
|
|
<h2 class="{{ .Type }}-subheading">{{ $subtitle }}</h2>
|
|
{{ end }}
|
|
{{ end }}
|
|
{{ if eq .Type "post" }}
|
|
<span class="post-meta">Posted on {{ .Date.Format .Site.Params.dateFormat }}</span>
|
|
{{ end }}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div> |