Show GIFs properly on add/edit forum post page
This commit is contained in:
parent
ad0eb6e17c
commit
63471e2e9b
|
@ -55,7 +55,7 @@ func Forum() http.HandlerFunc {
|
||||||
var pager = &models.Pagination{
|
var pager = &models.Pagination{
|
||||||
Page: 1,
|
Page: 1,
|
||||||
PerPage: config.PageSizeThreadList,
|
PerPage: config.PageSizeThreadList,
|
||||||
Sort: "updated_at desc",
|
Sort: "threads.updated_at desc",
|
||||||
}
|
}
|
||||||
pager.ParsePage(r)
|
pager.ParsePage(r)
|
||||||
|
|
||||||
|
|
|
@ -203,7 +203,13 @@
|
||||||
</h3>
|
</h3>
|
||||||
|
|
||||||
<!-- Container of img tags for the selected photo preview. -->
|
<!-- Container of img tags for the selected photo preview. -->
|
||||||
|
{{if and .CommentPhoto (HasSuffix .CommentPhoto.Filename ".mp4")}}
|
||||||
|
<video autoplay loop controls controlsList="nodownload" playsinline>
|
||||||
|
<source src="{{PhotoURL .CommentPhoto.Filename}}" type="video/mp4">
|
||||||
|
</video>
|
||||||
|
{{else}}
|
||||||
<img id="previewImage"{{if .CommentPhoto}} src="{{PhotoURL .CommentPhoto.Filename}}"{{end}}>
|
<img id="previewImage"{{if .CommentPhoto}} src="{{PhotoURL .CommentPhoto.Filename}}"{{end}}>
|
||||||
|
{{end}}
|
||||||
</div>
|
</div>
|
||||||
{{end}}
|
{{end}}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user