在向eclipse中粘貼html代碼的時候,發現了不能自動在雙引号後面加上斜線的問題,但是貌似隻有我不行,...... 現在我隻有猜想是我的eclipse版本不支援...
"<!DOCTYPE html>\r\n"
+ "<html en\">\r\n"
+ "<head>\r\n"
+ " <meta charset=\"UTF-8\">\r\n"
+ " <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\r\n"
+ " <meta http-equiv=\"X-UA-Compatible\" content=\"ie=edge\">\r\n"
+ " <title>使用者登入</title>\r\n"
+ "</head>\r\n"
+ "<body>\r\n"
+ " <form action=\""+request.getContextPath()+"/login\" method=\"post\">\r\n"
+ " <input type=\"text\" name=\"un\" value=\"\" placeholder=\"使用者名\">\r\n"
+ " <input type=\"password\" name=\"pwd\" placeholder=\"密碼\">\r\n"
+ " <button style=\"submit\">登入</button>\r\n"
+ " </form>\r\n<p style=\"color: red\">" + errorMessage
+ "</p>\r\n" + "</body>\r\n" + "</html>
粘貼之後的代碼應該類似于這樣..但是我從VSCODE中粘貼進去的代碼原封不動..求大佬指點...