diff options
author | Ugnich Anton | 2014-03-12 02:20:20 +0700 |
---|---|---|
committer | Ugnich Anton | 2014-03-12 02:20:20 +0700 |
commit | 4fb2d4cad66b24efff2913c3058e2ed581bbef39 (patch) | |
tree | 665570551d45ee350f6d203c74e75c12cdc37542 /src/java/com/juick/http/www/Home.java | |
parent | fe4e0d7058a77ec8715f1a15f9374ec86b6fb9a5 (diff) |
New post form
Diffstat (limited to 'src/java/com/juick/http/www/Home.java')
-rw-r--r-- | src/java/com/juick/http/www/Home.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/java/com/juick/http/www/Home.java b/src/java/com/juick/http/www/Home.java index c3a93107..41e85c0d 100644 --- a/src/java/com/juick/http/www/Home.java +++ b/src/java/com/juick/http/www/Home.java @@ -106,6 +106,19 @@ public class Home { out.println("<!--noindex-->"); } + if (visitor != null) { + out.println("<form action=\"/post\" method=\"post\" enctype=\"multipart/form-data\" onsubmit=\"return onsubmitNewMessage()\">"); + out.println("<section id=\"newmessage\">"); + out.println(" <textarea name=\"body\" placeholder=\"Новое сообщение...\" onclick=\"$('#newmessage>div').css('display','block')\" onkeypress=\"postformListener(this.form,event)\"></textarea>"); + out.println(" <div>"); + out.println(" <input type=\"text\" class=\"tags\" name=\"tags\" placeholder=\"Теги (через пробел)\"/>"); + out.println(" <div class=\"attach-photo\" onclick=\"attachCommentPhoto(this)\"></div>"); + out.println(" <input type=\"submit\" class=\"subm\" value=\"Отправить\"/>"); + out.println(" </div>"); + out.println("</section>"); + out.println("</form>"); + } + if (mids.size() > 0) { int ad_mid = 0; if (visitor != null && (paramShow == null || paramShow.equals("top") || paramShow.equals("all"))) { |