comparison src/main/java/jp/ac/u_ryukyu/ie/cr/bbs/local/ShowBoardMessageServlet.java @ 4:5acde010c6db

add jungle browsing system
author tatsuki
date Tue, 28 Jun 2016 19:45:55 +0900
parents 64a72a7a0491
children
comparison
equal deleted inserted replaced
3:f3d30646c863 4:5acde010c6db
38 38
39 _pw.write("<form action='" + createBoardMessagePath + "' method='POST'\n"); 39 _pw.write("<form action='" + createBoardMessagePath + "' method='POST'\n");
40 _pw.write("<p>Author : <input type='text' name='author'/> <input type='hidden' name='bname' value='" + _bname + "'/> EditKey : <input type='text' name='key'/></p>\n"); 40 _pw.write("<p>Author : <input type='text' name='author'/> <input type='hidden' name='bname' value='" + _bname + "'/> EditKey : <input type='text' name='key'/></p>\n");
41 _pw.write("<p>Message<br/> <input type='textarea' name='msg'/> </p>\n"); 41 _pw.write("<p>Message<br/> <input type='textarea' name='msg'/> </p>\n");
42 _pw.write("<p><input type='submit' value='submit'/></p>\n"); 42 _pw.write("<p><input type='submit' value='submit'/></p>\n");
43 GetAttributeImp attribute = bbs.getAttribute(_bname, "[-1]", "1"); 43 GetAttributeImp attribute = bbs.getAttribute(_bname, "[-1]", "-1");
44 Iterator<String> keys = attribute.getKeys(); 44 Iterator<String> keys = attribute.getKeys();
45 45
46 do { 46 do {
47 String key = keys.next(); 47 String key = keys.next();
48 String mesage = attribute.getMessage(key); 48 String mesage = attribute.getMessage(key);
49 _pw.write("<p>" + key + " = " + mesage + "</p>\n"); 49 _pw.write("<p>" + key + " = " + mesage + "</p>\n");
50 }while(keys.hasNext()); 50 } while (keys.hasNext());
51 51
52 _pw.write("</body></html>"); 52 _pw.write("</body></html>");
53 _pw.flush(); 53 _pw.flush();
54 } 54 }
55 } 55 }