FormattedDisplayTitle dynamically generates a title from the Post's contents if it doesn't already have an explicit title.
()
| 231 | // FormattedDisplayTitle dynamically generates a title from the Post's contents if it |
| 232 | // doesn't already have an explicit title. |
| 233 | func (p *Post) FormattedDisplayTitle() template.HTML { |
| 234 | if p.HTMLTitle != "" { |
| 235 | return p.HTMLTitle |
| 236 | } |
| 237 | return template.HTML(p.DisplayTitle()) |
| 238 | } |
| 239 | |
| 240 | // Summary gives a shortened summary of the post based on the post's title, |
| 241 | // especially for display in a longer list of posts. It extracts a summary for |
no test coverage detected