diff options
author | Trumeet <yuuta@yuuta.moe> | 2021-11-18 17:15:52 -0800 |
---|---|---|
committer | Trumeet <yuuta@yuuta.moe> | 2021-11-18 17:15:52 -0800 |
commit | 809d222a302874b9b9cf6620f0b960090ddbbe9e (patch) | |
tree | ea001bc7083c312fe376948fb884144eb93e77a4 | |
parent | 668388e6604f65009809f31f97e08315c380dc41 (diff) | |
download | mdrd-809d222a302874b9b9cf6620f0b960090ddbbe9e.tar mdrd-809d222a302874b9b9cf6620f0b960090ddbbe9e.tar.gz mdrd-809d222a302874b9b9cf6620f0b960090ddbbe9e.tar.bz2 mdrd-809d222a302874b9b9cf6620f0b960090ddbbe9e.zip |
feat: add a basic <head> section
-rw-r--r-- | main.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -84,8 +84,10 @@ int main() { cmark_node_free(document); printf("Content-Type: text/html\r\n" "Content-Length: %d\r\n" - "\r\n%s", - strlen(html) * sizeof(char), + "\r\n" + "<html><head><meta charset=\"utf-8\"></head><body>%s</body></html>", + (strlen("<html><head><meta charset=\"utf-8\"></head><body></body></html>") + strlen(html)) + * sizeof(char), html); free(html); fclose(file); |