diff --git a/html.c b/html.c
index 71ac1bd..97e7129 100644
--- a/html.c
+++ b/html.c
@@ -317,6 +317,7 @@ xs_html *html_note(snac *user, char *summary,
xs_html_attr("value", edit_id)));
xs_html_add(form,
+ xs_html_tag("p", NULL),
xs_html_tag("details",
xs_html_tag("summary",
xs_html_text(L("Attachment..."))),
@@ -332,10 +333,12 @@ xs_html *html_note(snac *user, char *summary,
/* add poll controls */
if (poll) {
xs_html_add(form,
+ xs_html_tag("p", NULL),
xs_html_tag("details",
xs_html_tag("summary",
xs_html_text(L("Poll..."))),
- xs_html_tag("p", NULL),
+ xs_html_tag("p",
+ xs_html_text(L("Poll options (one per line, up to 8):"))),
xs_html_tag("textarea",
xs_html_attr("class", "snac-textarea"),
xs_html_attr("name", "poll_options"),
@@ -351,6 +354,7 @@ xs_html *html_note(snac *user, char *summary,
xs_html_tag("option",
xs_html_attr("value", "on"),
xs_html_text(L("Multiple choices")))),
+ xs_html_text(" "),
xs_html_tag("select",
xs_html_attr("name", "poll_end_secs"),
xs_html_tag("option",
@@ -1944,54 +1948,15 @@ xs_str *html_people_list(snac *snac, xs_str *os, xs_list *list, const char *head
/* the post textarea */
xs *dm_div_id = xs_fmt("%s_%s_dm", md5, t);
- xs *dm_action = xs_fmt("%s/admin/note", snac->actor);
xs *dm_form_id = xs_fmt("%s_reply_form", md5);
- xs_html *dm_textarea = xs_html_tag("div",
- xs_html_tag("details",
- xs_html_tag("summary",
- xs_html_text(L("Direct Message..."))),
- xs_html_tag("p", NULL),
- xs_html_tag("div",
- xs_html_attr("class", "snac-note"),
- xs_html_attr("id", dm_div_id),
- xs_html_tag("form",
- xs_html_attr("autocomplete", "off"),
- xs_html_attr("method", "post"),
- xs_html_attr("action", dm_action),
- xs_html_attr("enctype", "multipart/form-data"),
- xs_html_attr("id", dm_form_id),
- xs_html_tag("textarea",
- xs_html_attr("class", "snac-textarea"),
- xs_html_attr("name", "content"),
- xs_html_attr("rows", "4"),
- xs_html_attr("wrap", "virtual"),
- xs_html_attr("required", "required"),
- xs_html_attr("placeholder", ""),
- xs_html_text("")),
- xs_html_sctag("input",
- xs_html_attr("type", "hidden"),
- xs_html_attr("name", "to"),
- xs_html_attr("value", actor_id)),
- xs_html_tag("p", NULL),
- xs_html_tag("details",
- xs_html_tag("summary",
- xs_html_text(L("Attachment..."))),
- xs_html_tag("p", NULL),
- xs_html_sctag("input",
- xs_html_attr("type", "file"),
- xs_html_attr("name", "attach")),
- xs_html_sctag("input",
- xs_html_attr("type", "text"),
- xs_html_attr("name", "alt_text"),
- xs_html_attr("placeholder", L("Attachment description")))),
- xs_html_tag("p", NULL),
- xs_html_sctag("input",
- xs_html_attr("type", "submit"),
- xs_html_attr("class", "button"),
- xs_html_attr("value", L("Post")))),
- xs_html_tag("p", NULL))),
- xs_html_tag("p", NULL));
+ xs_html *dm_textarea = html_note(snac, "Direct Message...",
+ dm_div_id, dm_form_id,
+ "", "",
+ NULL, actor_id,
+ xs_stock_false, "",
+ xs_stock_false, NULL,
+ NULL, 0);
xs_html_add(snac_controls, dm_textarea);