javabean动作报错求解救(有图有码)
我自己觉得可能代码放的地方有问题,还请大佬解答:
package bao; public class Javabean { private String name; private String mima; public Javabean() {} public void setName(String name){ this.name=name; } public String getName(){ return name; } public void setMima(String mima){ this.mima=mima; } public String getMima(){ return mima; } }
<%@ page contentType="text/html;charset=UTF-8" language="java" %> <html> <head> <title>Title</title> </head> <body> <jsp:useBean id="ooo" scope="page" class="bao.Javabean"/> 用户名:<%= ooo.setName("真的") %><br> 密码:<%= ooo.setMima("23") %><br> </body> </html>