Browse Source

Print body structure tree

master
Simon Ser 4 years ago
parent
commit
61f2f3e139
No known key found for this signature in database GPG Key ID: FDE7BE0E88F5E48
1 changed files with 16 additions and 1 deletions
  1. +16
    -1
      public/message.html

+ 16
- 1
public/message.html View File

@@ -6,6 +6,21 @@

<h2>{{.Message.Envelope.Subject}}</h2>

<pre>{{.Body}}</pre>
{{define "message-part"}}
{{.MIMEType}}/{{.MIMESubType}}
{{if gt (len .Parts) 0}}
<ul>
{{range .Parts}}
<li>{{template "message-part" .}}</li>
{{end}}
</ul>
{{end}}
{{end}}

{{template "message-part" .Message.BodyStructure}}

{{if .Body}}
<pre>{{.Body}}</pre>
{{end}}

{{template "foot"}}

Loading…
Cancel
Save