{{ $dir := string (.Get "gallery_dir") }}
{{ range (readDir (print "/static" $dir)) }} {{- $image := resources.Get (printf "%s/%s" $dir .Name) -}} {{- $imageurl := printf "%s/%s" $dir .Name -}} {{- $imagetitle := index (split .Name ".") 0 -}}
{{ $imagetitle }}
{{ end }}