From de280b624c6a190954b61463b896c116440ae42a Mon Sep 17 00:00:00 2001 From: cel Date: Sun, 31 May 2020 14:52:09 -0400 Subject: [PATCH] Use note title as page title --- zet.dpi.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/zet.dpi.c b/zet.dpi.c index 5ac25dd..5c39186 100644 --- a/zet.dpi.c +++ b/zet.dpi.c @@ -620,9 +620,15 @@ static int dpi_serve_zet(int fd, char *path) { rc = dpi_send_header(fd, "text/html"); rc |= dprintf(fd, "" - "ยง%s" + ""); + char buf[128]; + char *title = zet_get_title(id, buf, sizeof(buf)); + rc |= write_html(fd, title, strlen(title)); + rc |= dprintf(fd, + "" "" - "", id); + ""); + rc |= write_topbar(fd, PAGE_ZET, id); rc |= dprintf(fd, ""