[OCaml] Mobile-friendly clone of cgit.
feat add W3C 'Validate' link in page footer
Links to validator.w3.org/check/referer so the current page can be validated directly, similar to Org mode HTML exports.
lib/views/layout.ml
@@ -86,8 +86,14 @@
86
86
let page_footer user_name =
87
87
let now = Unix.(time () |> localtime) in
88
88
let year = string_of_int (now.tm_year + 1900) in
89
Removed:
if user_name = "" then HTML.footer [] [ txt "Copyright %s" year ]
90
Removed:
else HTML.footer [] [ txt "Copyright %s %s" year user_name ]
89
Added:
HTML.(
90
Added:
footer []
91
Added:
[
92
Added:
(if user_name = "" then txt "Copyright %s" year
93
Added:
else txt "Copyright %s %s" year user_name);
94
Added:
txt " — ";
95
Added:
a [ href "https://validator.w3.org/check/referer" ] [ txt "Validate" ];
96
Added:
])
91
97
92
98
let head page_title =
93
99
let open HTML in