文件的操作
String username=request.getParameter( "username ");
String usercode=request.getParemeter( "usercode ");
<%try{
File f=new File( "E:\users ", "student.txt ");
FileInputStream in=new FinleInputStream(f);
DataInputStream DataIn=new DataInputStream(in);
String name= "ok ",code= "ok ";
while((name=DataIn.readUTF())!=null){
code=DataIn.readUTF();
if(username==name&&usercode==code)
out.print( "Log In Successly ");
}DataIn.close();
}
catch(
IOException ee){}%>
E:\study\Java\MyWeb\build\generated\src\org\apache\jsp\Login_jsp.java:66: 非法的 Unicode 转义
File f=new File( "E:\users ", "student.txt ");
------解决方案--------------------改为
File f=new File( "E:\\users ", "student.txt ");