Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {{ partial "header.html" . }}
- <!-- Page Header -->
- <div class="row">
- <div class="col-md-12">
- <h3>Портфолио</h3>
- </div>
- </div>
- {{ $portfolio := where .Data.Pages "Section" "portfolio" }}
- {{ $len := len $portfolio }}
- {{ $len := sub $len 1 }}
- {{ range $index, $el := $portfolio }}
- {{ if modBool $index 2 }}
- <div class="row">
- <div class="col-md-6">
- <a href="{{ .Permalink }}">
- <img src="{{ .Site.BaseUrl }}images/portfolio/{{ .Params.photo }}" alt="" class="img-responsive">
- <h5>{{ .Title }}</h5>
- </a>
- </div>
- {{ else }}
- <div class="col-md-6">
- <a href="{{ .Permalink }}">
- <img src="{{ .Site.BaseUrl }}images/portfolio/{{ .Params.photo }}" alt="" class="img-responsive">
- <h5>{{ .Title }}</h5>
- </a>
- </div>
- </div>
- {{ end }}
- {{ $zero := sub $len $index }}
- {{ if eq $zero 0 }}
- <div class="col-md-6">
- </div>
- </div>
- {{ end }}
- {{ end }}
- {{ partial "footer.html" . }}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement