From b1f9b9c1459cb9a30ebf80721aff6ef788d1f891 Mon Sep 17 00:00:00 2001 From: Lars Hjemli Date: Sat, 23 Feb 2008 22:45:33 +0100 Subject: Introduce html.h All html-functions can be quite easily separated from the rest of cgit, so lets do it; the only issue was html_filemode which uses some git-defined macros so the function is moved into ui-shared.c::cgit_print_filemode(). Signed-off-by: Lars Hjemli --- html.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 html.h (limited to 'html.h') diff --git a/html.h b/html.h new file mode 100644 index 0000000..63f4551 --- /dev/null +++ b/html.h @@ -0,0 +1,18 @@ +#ifndef HTML_H +#define HTML_H + +extern int htmlfd; + +extern void html(const char *txt); +extern void htmlf(const char *format,...); +extern void html_txt(char *txt); +extern void html_ntxt(int len, char *txt); +extern void html_attr(char *txt); +extern void html_hidden(char *name, char *value); +extern void html_option(char *value, char *text, char *selected_value); +extern void html_link_open(char *url, char *title, char *class); +extern void html_link_close(void); +extern void html_fileperm(unsigned short mode); +extern int html_include(const char *filename); + +#endif /* HTML_H */ -- cgit v1.2.3 From e87e89633383b8b75c68c98be3e0c14212109de2 Mon Sep 17 00:00:00 2001 From: Lars Hjemli Date: Tue, 8 Apr 2008 21:11:36 +0200 Subject: Move cgit_parse_query() from parsing.c to html.c as http_parse_querystring() This is a generic http-function. Signed-off-by: Lars Hjemli --- html.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'html.h') diff --git a/html.h b/html.h index 63f4551..e6fdc54 100644 --- a/html.h +++ b/html.h @@ -15,4 +15,6 @@ extern void html_link_close(void); extern void html_fileperm(unsigned short mode); extern int html_include(const char *filename); +extern int http_parse_querystring(char *txt, void (*fn)(const char *name, const char *value)); + #endif /* HTML_H */ -- cgit v1.2.3