Toevoegen shortcode om sponsor in content te 'includen'
This commit is contained in:
parent
2bc3e66918
commit
46f4d2925b
1 changed files with 12 additions and 0 deletions
12
themes/nluug/layouts/shortcodes/insert-sponsor.html
Normal file
12
themes/nluug/layouts/shortcodes/insert-sponsor.html
Normal file
|
@ -0,0 +1,12 @@
|
|||
{{ $id := .Get "id" }}
|
||||
{{ with (index $.Site.Data.sponsoren $id) }}
|
||||
<div>
|
||||
<strong>{{ .name }}</strong>
|
||||
{{ if .icon_small }}
|
||||
{{ $alttext := printf "Logo van %s" .name }}
|
||||
{{ if .url }}<a href="{{ .url }}" rel="nofollow">{{ end }}
|
||||
{{ partial "show-image.html" (dict "context" . "image" .icon_small "alt" $alttext) }}
|
||||
{{ if .url }}</a>{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
Loading…
Reference in a new issue