Pracownia.Programowania/views/write.html
2018-12-22 20:04:32 +01:00

27 lines
878 B
HTML

<div class="row">
<div class="col-xs-2">
{{ if.Id }}
<a href="/deletePost/{{.Id}}">Delete</a>
{{ end }}
</div>
<div class="col-xs-4">
<form action="/savePost" method="POST" role="form">
<input type="hidden" name="id" value="{{.Id}}"/>
<div class="form-group">
<label for="title">Tytul</label>
<input type="text" class="form-control" id="title" name="title" value ="{{.Title}}"/>
</div>
<div class="form-group">
<label for="content">Content</label>
<textarea name="content" id="content">{{.ContentMd}}</textarea>
</div>
<button type="submit" class="btn btn-default">Submit</button>
</form>
</div>
<div class="col-xs-6" id="md">
{{ .ContentHtml | unescape}}
</div>
</div>