nirvash/templates/file_mkdir_process.html

19 lines
No EOL
462 B
HTML

{{ $slug := ((.Context).Value "params").Slug }}
{{ $newDir := .FormValue "dirname" }}
{{ $mkdirError := ((.Context).Value "file-manager").MkDir $slug $newDir }}
{{ template "header" . }}
{{ if $mkdirError }}
<h2>Directory Creation Error</h2>
<span class="adapter-error">{{($mkdirError).Error}}</span>
{{ else }}
<h2>Directory Created</h2>
<span class="adapter-success">The directory has been created successfully</span>
{{ end }}
{{ template "footer" . }}