summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPatrick McDermott <pj@pehjota.net>2017-11-04 14:12:12 (EDT)
committer Patrick McDermott <pj@pehjota.net>2017-11-04 14:12:12 (EDT)
commit49118c9a5dac0f11d2f34459606df84b3f215284 (patch)
tree339480e5479abe5f6eb530b8c5127744d1e32de9 /src
parentf44547820a75d613694ce52da1cda440210e514d (diff)
downloadmarquee-49118c9a5dac0f11d2f34459606df84b3f215284.zip
marquee-49118c9a5dac0f11d2f34459606df84b3f215284.tar.gz
marquee-49118c9a5dac0f11d2f34459606df84b3f215284.tar.bz2
mq_html_submit(): New function
Diffstat (limited to 'src')
-rw-r--r--src/utils/html.c8
-rw-r--r--src/utils/html.h3
2 files changed, 11 insertions, 0 deletions
diff --git a/src/utils/html.c b/src/utils/html.c
index e5d2993..95f7d11 100644
--- a/src/utils/html.c
+++ b/src/utils/html.c
@@ -849,6 +849,14 @@ mq_html_label(const gchar *for_id, const gchar *label, gboolean add_colon)
}
gchar *
+mq_html_submit(const gchar *name, const gchar *label, gboolean disabled)
+{
+ return g_strdup_printf(
+ "<input type=\"submit\" name=\"%s\" value=\"%s\"%s>\n",
+ name, label, disabled ? " disabled=\"disabled\"" : "");
+}
+
+gchar *
mq_html_input_iframe(const gchar *src)
{
return g_strdup_printf("<iframe src=\"%s\"></iframe>", src);
diff --git a/src/utils/html.h b/src/utils/html.h
index 63d20f9..27e0cfe 100644
--- a/src/utils/html.h
+++ b/src/utils/html.h
@@ -94,6 +94,9 @@ gchar *
mq_html_label(const gchar *for_id, const gchar *label, gboolean add_colon);
gchar *
+mq_html_submit(const gchar *name, const gchar *label, gboolean disabled);
+
+gchar *
mq_html_input_iframe(const gchar *src);
G_END_DECLS