1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  def to_html
    # endpoint doesn't matter here so set to something bogus
    # to prevent TM from asking for one...
    @endpoint = 'x'
    _format = ENV['TM_SCOPE']
    _doc = "#{post['description']}"
    _doc += "#{post['mt_text_more']}" if post['mt_text_more']
    _base = %Q{<base href="#{headers['Link']}" />} if headers['Link']
    print <<-HTML
<html><head><title>#{post['title']}</title>
#{_base}
<style type="text/css">
  body {  
    background-color: #eee;
  }
  body > h1 {
    font-size: large;
  }
  .contents { 
    background: white;
    font-family: Georgia, serif;
    font-size: 13px;
    border: 1px #888 solid;
    padding: 0 1em;
  }
</style>
</head>
<body>
<h1>#{post['title']}</h1>
<div class="contents">
HTML