Browse Source

made it display authors or dates if one is available

Izaya 2 months ago
parent
commit
bcd90e907c
2 changed files with 5 additions and 2 deletions
  1. 3
    0
      blog.lua
  2. 2
    2
      genpages.lua

+ 3
- 0
blog.lua View File

@@ -38,6 +38,9 @@ for i = #ftab, 1, -1 do
38 38
   end
39 39
   f:write("</div>")
40 40
  end
41
+ if page.author or page.date then
42
+  f:write('<h4><div class="wrapper"><div class="left-column">By '..(page.author or "")..'</div><div class="right-column">'..(page.date or "")..'</div></div></h4>\n')
43
+ end
41 44
  if page.tags then
42 45
   f:write("<h4>Tags: ")
43 46
   for w in page.tags:gmatch("%S+") do

+ 2
- 2
genpages.lua View File

@@ -44,8 +44,8 @@ for k,infile in pairs(mdfiles) do
44 44
  f:write("<html><head><title>"..(page.title or "").."</title>\n")
45 45
  f:write(sitelib.header)
46 46
  f:write(page.html)
47
- if page.author and page.date then
48
-  f:write('<h4><div class="wrapper"><div class="left-column">By '..(page.author or "")..'</div><div class="right-column">'..(page.date or "")..'</div></div></h3>\n')
47
+ if page.author or page.date then
48
+  f:write('<h4><div class="wrapper"><div class="left-column">By '..(page.author or "")..'</div><div class="right-column">'..(page.date or "")..'</div></div></h4>\n')
49 49
  end
50 50
  if page.tags then
51 51
   f:write("<h4>Tags: ")