summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2013-12-30 19:18:44 +0000
committerTed Trask <ttrask01@yahoo.com>2013-12-30 19:18:44 +0000
commit0f3a2a14db8740ccc987ac623ae68f48c154e2a3 (patch)
tree4e28e4994e2f7a1ea49c520a5ccccfa12da52e31 /app
parent8ac4773598507456d31e5942cdf2b23981fb8dfa (diff)
downloadacf-core-0f3a2a14db8740ccc987ac623ae68f48c154e2a3.tar.bz2
acf-core-0f3a2a14db8740ccc987ac623ae68f48c154e2a3.tar.xz
Fix HTML 4.01 Strict syntax errors in template-html.lsp
Diffstat (limited to 'app')
-rw-r--r--app/template-html.lsp56
1 files changed, 31 insertions, 25 deletions
diff --git a/app/template-html.lsp b/app/template-html.lsp
index 4da3175..9277736 100644
--- a/app/template-html.lsp
+++ b/app/template-html.lsp
@@ -59,7 +59,7 @@ end
<p><%= html.html_escape(hostname or "unknown hostname") %></p>
<div class="tailer"></div>
</div>
- <span class="mute">
+ <div class="mute">
<p>
<% local ctlr = pageinfo.script .. "/acf-util/logon/"
@@ -71,7 +71,7 @@ end
|
<a href="<%= html.html_escape(pageinfo.wwwprefix) %>/">home</a> |
<a href="http://www.alpinelinux.org">about</a>
- </p></span>
+ </p></div>
<div class="tailer"></div>
</div> <!-- header -->
@@ -87,21 +87,24 @@ end
<%
local class
local tabs
- io.write ( "<ul>")
- for x,cat in ipairs(session.menu.cats) do
- io.write (string.format("\n\t\t\t\t<li>%s\n\t\t\t\t\t<ul>\n", html.html_escape(cat.name))) --start row
- for y,group in ipairs(cat.groups) do
- class=""
- if not tabs and group.controllers[pageinfo.prefix .. pageinfo.controller] then
- class="class='selected'"
- tabs = group.tabs
+ if (#session.menu.cats > 0) then
+ io.write ( "<ul>")
+ for x,cat in ipairs(session.menu.cats) do
+ io.write (string.format("\n\t\t\t\t<li>%s\n\t\t\t\t\t<ul>\n", html.html_escape(cat.name))) --start row
+ for y,group in ipairs(cat.groups) do
+ class=""
+ if not tabs and group.controllers[pageinfo.prefix .. pageinfo.controller] then
+ class="class='selected'"
+ tabs = group.tabs
+ end
+ io.write (string.format("\t\t\t\t\t\t<li %s><a %s href=\"%s%s%s/%s\">%s</a></li>\n",
+ class,class,html.html_escape(pageinfo.script),html.html_escape(group.tabs[1].prefix), html.html_escape(group.tabs[1].controller), html.html_escape(group.tabs[1].action), html.html_escape(group.name) ))
end
- io.write (string.format("\t\t\t\t\t\t<li %s><a %s href=\"%s%s%s/%s\">%s</a></li>\n",
- class,class,html.html_escape(pageinfo.script),html.html_escape(group.tabs[1].prefix), html.html_escape(group.tabs[1].controller), html.html_escape(group.tabs[1].action), html.html_escape(group.name) ))
+ io.write ( "\t\t\t\t\t</ul>" )
+ io.write ( "\t\t\t\t</li>\n")
end
- io.write ( "\t\t\t\t\t</ul>" )
- end
- io.write ( "\n\t\t\t\t</li>\n\t\t\t</ul>\n")
+ io.write ( "\n\t\t\t</ul>\n")
+ end
%>
<div class="tailer">
@@ -126,19 +129,22 @@ end
<h3 class="hide">[Submenu]</h3>
</div>
- <ul>
- <% local class="" %>
- <% for x,tab in pairs(tabs or {}) do
- if tab.prefix == pageinfo.prefix and tab.controller == pageinfo.controller and tab.action == pageinfo.action then
- class="class='selected'"
- else
- class=""
- end
- io.write (string.format('<li %s><a %s href="%s%s%s/%s">%s</a></li>\n',
+ <%
+ local class=""
+ if (tabs and #tabs > 0) then
+ io.write ( "<ul>")
+ for x,tab in pairs(tabs or {}) do
+ if tab.prefix == pageinfo.prefix and tab.controller == pageinfo.controller and tab.action == pageinfo.action then
+ class="class='selected'"
+ else
+ class=""
+ end
+ io.write (string.format('<li %s><a %s href="%s%s%s/%s">%s</a></li>\n',
class,class,html.html_escape(pageinfo.script),html.html_escape(tab.prefix),html.html_escape(tab.controller),html.html_escape(tab.action),html.html_escape(tab.name) ))
+ end
+ io.write ( "</ul>")
end
%>
- </ul>
<div class="tailer">
</div>