本文目录一览:
- 1、急求一个用jsp做的网上购物系统的源代码!
- 2、jsp做的网络系统源代码谁有?
- 3、jsp登陆界面源代码
- 4、急求一个用JSP做的网上商城系统设计与实现——后台管理子系统的源代码!
- 5、求一个JSP 网络银行或者ATM源代码
急求一个用jsp做的网上购物系统的源代码!
可以通过百度Hi告诉我你的问题
有时间可以搞定你面临的问题
如果你有相近的要求也可以示意我
ES:\\BA013AB0A29410B4D0D3CA74500E49BA
交易提醒:预付定金是陷阱
交易提醒:用户名中包含联系方式勿轻信
jsp做的网络系统源代码谁有?
就是用JSP加几个小图片来实现一个比例的东西
很简单的东西
而且很容易实现
如果要做的复杂点
就做动态的Div的Ajax的那种要用户自己去配置
那个稍微麻烦点
jsp登陆界面源代码
1、login.jsp文件
%@ page language="java" contentType="text/html; charset=GB18030"
pageEncoding="GB18030"%
%@ page import="java.util.*" %
!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
html
head
title登录页面/title
/head
body
form name="loginForm" method="post" action="judgeUser.jsp"
table
tr
td用户名:input type="text" name="userName" id="userName"/td
/tr
tr
td密码:input type="password" name="password" id="password"/td
/tr
tr
tdinput type="submit" value="登录" style="background-color:pink" input
type="reset" value="重置" style="background-color:red"/td
/tr
/table
/form
/body
/html
2、judge.jsp文件
%@ page language="java" contentType="text/html; charset=GB18030"
pageEncoding="GB18030"%
%@ page import="java.util.*" %
!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
html
head
title身份验证/title
/head
body
%
request.setCharacterEncoding("GB18030");
String name = request.getParameter("userName");
String password = request.getParameter("password");
if(name.equals("abc") password.equals("123")) {
3、afterLogin.jsp文件
%
jsp:forward page="afterLogin.jsp"
jsp:param name="userName" value="%=name%"/
/jsp:forward
%
}
else {
%
jsp:forward page="login.jsp"/
%
}
%
/body
/html
%@ page language="java" contentType="text/html; charset=GB18030"
pageEncoding="GB18030"%
!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
html
head
title登录成功/title
/head
body
%
request.setCharacterEncoding("GB18030");
String name = request.getParameter("userName");
out.println("欢迎你:" + name);
%
/body
/html
扩展资料:
java web登录界面源代码:
1、Data_uil.java文件
import java.sql.*;
public class Data_uil
{
public Connection getConnection()
{
try{
Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver");
}catch(ClassNotFoundException e)
{
e.printStackTrace();
}
String user="***";
String password="***";
String url="jdbc:sqlserver://127.0.0.1:1433;DatabaseName=***";
Connection con=null;
try{
con=DriverManager.getConnection(url,user,password);
}catch(SQLException e)
{
e.printStackTrace();
}
return con;
}
public String selectPassword(String username)
{
Connection connection=getConnection();
String sql="select *from login where username=?";
PreparedStatement preparedStatement=null;
ResultSet result=null;
String password=null;
try{
preparedStatement=connection.prepareStatement(sql);
preparedStatement.setString(1,username);
result=preparedStatement.executeQuery();//可执行的 查询
if(result.next())
password=result.getString("password");
}catch(SQLException e){
e.printStackTrace();
}finally
{
close(preparedStatement);
close(result);
close(connection);
}
System.out.println("找到的数据库密码为:"+password);
return password;
}
public void close (Connection con)
{
try{
if(con!=null)
{
con.close();
}
}catch(SQLException e)
{
e.printStackTrace();
}
}
public void close (PreparedStatement preparedStatement)
{
try{
if(preparedStatement!=null)
{
preparedStatement.close();
}
}catch(SQLException e)
{
e.printStackTrace();
}
}
public void close(ResultSet resultSet)
{
try{
if(resultSet!=null)
{
resultSet.close();
}
}catch(SQLException e)
{
e.printStackTrace();
}
}
}
2、login_check.jsp:文件
%@ page language="java" contentType="text/html; charset=utf-8"
pageEncoding="utf-8"%
!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" ""
html
head
meta http-equiv="Content-Type" content="text/html; charset=utf-8"
title验证用户密码/title
/head
body
jsp:useBean id="util" class="util.Data_uil" scope="page" /
%
String username=(String)request.getParameter("username");
String password=(String)request.getParameter("password");
if(username==null||"".equals(username))
{
out.print("script language='javaScript' alert('用户名不能为空');/script");
response.setHeader("refresh", "0;url=user_login.jsp");
}
else
{
System.out.println("输入的用户名:"+username);
String passwordInDataBase=util.selectPassword(username);
System.out.println("密码:"+passwordInDataBase);
if(passwordInDataBase==null||"".equals(passwordInDataBase))
{
out.print("script language='javaScript' alert('用户名不存在');/script");
response.setHeader("refresh", "0;url=user_login.jsp");
}
else if(passwordInDataBase.equals(password))
{
out.print("script language='javaScript' alert('登录成功');/script");
response.setHeader("refresh", "0;url=loginSucces.jsp");
}
else
{
out.print("script language='javaScript' alert('密码错误');/script");
response.setHeader("refresh", "0;url=user_login.jsp");
}
}
%
/body
/html
3、loginSucces.jsp文件
%@ page language="java" contentType="text/html; charset=utf-8"
pageEncoding="utf-8"%
!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" ""
html
head
meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"
titleInsert title here/title
/head
body
hr size="10" width="26%" align="left" color="green"
font size="6" color="red" 登录成功 /font
hr size="10" width="26%" align="left" color="green"
/body
/html
4、user_login.jsp文件
%@ page language="java" contentType="text/html; charset=utf-8"
pageEncoding="utf-8"%
!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" ""
html
head
meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"
title登录界面/title
/head
body background="C:\Users\win8\workspace\Login\image\9dcbdc339e72a5663b5c289fb5573c13_10.jpg"
center
brbrbrbrbrbr
h1 style="color:yellow"Login/h1
br
form name="loginForm" action="login_check.jsp" method="post"
table Border="0"
tr
td账号/td
tdinput type="text" name="username"/td
/tr
tr
td密码/td
tdinput type="password" name="password"
/td
/tr
/table
br
input type="submit" value="登录" style="color:#BC8F8F"
/form
/center
/body
/html
急求一个用JSP做的网上商城系统设计与实现——后台管理子系统的源代码!
我可以提供给你参考。
如果只是产品展示和订单比较简单;
如果要在线支付和库存管理就很复杂了。
而且要根据行业,例如零售、电子、衣服等,对后台的要求也差别很大。
求一个JSP 网络银行或者ATM源代码
import java.util.Scanner;
import java.util.Date;
public class ATM {
public static void main (String[] args) {
System.out.println("您好,欢迎使用农业银行优惠卡!");
int a=123456;
int jine;
int flag=0,bianhao=1023;
int mima;
int anjian;
int ye=0;
int xianshi,dayin;
int year,month,date;
String zhanghao="6228480270673875612",zhuanzhanghao;
Scanner sc=new Scanner(System.in);
for(int i=1;i=3;i++){
System.out.println("请输入密码:(6位数字)");
mima=sc.nextInt();
if(a==mima)
{
System.out.println ("密码正确请选择业务");
for(;;){
System.out.println ("取款\t~1~");
System.out.println ("转账\t~2~");
System.out.println ("存现\t~3~");
System.out.println ("更改密码~4~");
System.out.println ("查询余额~5~");
System.out.println ("取卡\t~0~");
anjian=sc.nextInt();
if(anjian==1)
{
if(ye100)
{
System.out.println ("您的余额不足100元,请您及时存现");
break;
}
int qukuan;
for(;;)
{
for(;;)
{
System.out.println ("---------------取款功能--------------");
System.out.println ("请输入您要取款的份额:");
System.out.println ("\t100\t200\t500\t");
qukuan=sc.nextInt();
if(qukuan=ye)
{
break;
}
else{
System.out.println ("余额不足,取消交易");
}
}if(qukuan==100||qukuan==200||qukuan==500)
{
break;
}
else
{
System.out.println ("您的输入有误请输入正百的数");
}
}
ye-=qukuan;
System.out.println ("交易正在处理~请稍候~z~z~z~z~z~z~z~~~~~~~");
System.out.println ("请您收好您的"+qukuan+"元"+"钞票----15秒钟自动收回");
System.out.println ("-----------------------------------------------------");
System.out.println ("是否显示余额?显示:1不显示:2");
xianshi=sc.nextInt();
if(xianshi==1)
{
System.out.println ("您的余额为"+ye+"元");
System.out.println ("--------------------------------");
System.out.println ("为了您和您家人的幸福,请节约用钱");
System.out.println ("--------------------------------");
}
System.out.println ("是否打印取款凭条?打印:1 不打印:2");
dayin=sc.nextInt();
Date dd=new Date();
if(dayin==1)
{
System.out.println ("-----------------------中国农业银行-------------------------");
System.out.println ("\t\t\t----------取款凭条-----------\t\t\t");
System.out.println ("帐号:"+zhanghao);
System.out.println ("取款份额:"+qukuan);
System.out.println ("余额:"+ye);
System.out.println ("日期:"+dd.toLocaleString());
System.out.println ("------------------------------------------------------------");
System.out.println ("\t\t\t机器编号:"+bianhao);
System.out.println ("------------------------------------------------------------");
}
int ji;
System.out.println ("是否继续业务:继续:1 取卡:2");
ji=sc.nextInt();
if(ji==1)
{
continue;
}
if(ji==2)
{
System.out.println ("请收回您的磁卡,下次再见");
break;
}
}
if(anjian==2)
{
int zhuanzhang;
for(;;)
{
System.out.println ("---------------转账功能----------------");
System.out.println ("请输入您要转账的份额:");
zhuanzhang=sc.nextInt();
if(zhuanzhang%100==0)
{
if(ye-zhuanzhang=00)
{
break;
}
else
{
System.out.println ("余额不足,请重新输入");
}
}
else
{
System.out.println ("您的输入无效");
}
}
for(;;)
{
System.out.println ("请输入您要转账的账号:(19位)");
zhuanzhanghao=sc.next();
if(zhuanzhanghao.length()==19)
{
break;
}
else
{
System.out.println ("帐号输入有误,请重新输入");
}
}
System.out.println ("是否继续转账?继续:1 取消:2");
int anjian2;
anjian2=sc.nextInt();
if(anjian2==1)
{
ye-=zhuanzhang;
System.out.println ("正在转账-请稍候~~~~");
System.out.println ("转帐成功");
}
System.out.println ("-----------");
System.out.println ("是否显示余额?显示:1不显示:2");
xianshi=sc.nextInt();
if(xianshi==1)
{
System.out.println ("您的余额为"+ye+"元");
System.out.println ("--------------------------------");
System.out.println ("为了您和您家人的幸福,请节约用钱");
System.out.println ("--------------------------------");
}
System.out.println ("是否打印取款凭条?打印:1 不打印:2");
dayin=sc.nextInt();
Date dd=new Date();
if(dayin==1)
{
System.out.println ("-----------------------中国农业银行-------------------------");
System.out.println ("\t\t\t----------转账凭条-----------\t\t\t");
System.out.println ("帐号:"+zhanghao);
System.out.println ("转账帐号:"+zhuanzhanghao);
System.out.println ("转账份额:"+zhuanzhang);
System.out.println ("余额:"+ye);
System.out.println ("日期:"+dd.toLocaleString());
System.out.println ("------------------------------------------------------------");
System.out.println ("\t\t\t机器编号:"+bianhao);
System.out.println ("------------------------------------------------------------");
}
int ji;
System.out.println ("是否继续业务:继续:1 取卡:2");
ji=sc.nextInt();
if(ji==1)
{
continue;
}
else
{
System.out.println ("请收回您的磁卡,下次再见");
break;
}
}
if(anjian==3)
{
for(;;)
{
System.out.println ("---------------存现功能---------------");
System.out.println ("请输入您要存款的金额");
jine=sc.nextInt();
if(jine%100==0)
{
break;
}
else
{
System.out.println ("您的输入有误,请输入正百的输入");
}
}
System.out.println ("请将您的钞票放入到机器开起的口中(注意:平放!!)");
System.out.println ("正在清点~~~~~z~~~~~z~~~~~z~~~~~z~~~~z~~~~~~z~~~~");
System.out.println ("输入与放入一至;存现成功");
ye+=jine;
System.out.println ("是否显示余额?显示:1不显示:2");
xianshi=sc.nextInt();
if(xianshi==1)
{
System.out.println ("您的余额为"+ye+"元");
System.out.println ("--------------------------------");
System.out.println ("为了您和您家人的幸福,请节约用钱");
System.out.println ("--------------------------------");
}
System.out.println ("是否打印取款凭条?打印:1 不打印:2");
dayin=sc.nextInt();
Date dd=new Date();
if(dayin==1)
{
System.out.println ("-----------------------中国农业银行-------------------------");
System.out.println ("\t\t\t----------存现凭条-----------\t\t\t");
System.out.println ("帐号:"+zhanghao);
System.out.println ("存现份额:"+jine);
System.out.println ("余额:"+ye);
System.out.println ("日期:"+dd.toLocaleString());
System.out.println ("------------------------------------------------------------");
System.out.println ("\t\t\t机器编号:"+bianhao);
System.out.println ("------------------------------------------------------------");
}
int ji;
System.out.println ("是否继续业务:继续:1 取卡:2");
ji=sc.nextInt();
if(ji==1)
{
continue;
}
else
{
System.out.println ("请收回您的磁卡,下次再见");
break;
}
}
if(anjian==4)
{
int ym,xm,qxm,flag1=0;
for(int j=0;j3;j++)
{
System.out.println ("------------------改密功能----------------------");
System.out.println ("请输入原始密码:");
ym=sc.nextInt();
if(ym==a)
{
System.out.println ("密码正确");
for(;;)
{
System.out.println ("请输入新密码:");
xm=sc.nextInt();
System.out.println ("请再次输入新密码");
qxm=sc.nextInt();
if(xm==qxm)
{
a=xm;
System.out.println ("密码更改成功,请您牢记您的密码");
break;
}
else
{
System.out.println ("两次输入不一致,请重新输入");
}
}
flag1=1;
break;
}
else
{
System.out.println ("密码错误");
}
}
if(flag1==0)
{
System.out.println ("三次输入错误,密码更改失败");
}
int ji;
System.out.println ("是否继续业务:继续:1 取卡:2");
ji=sc.nextInt();
if(ji==1)
{
continue;
}
else
{
System.out.println ("请收回您的磁卡,下次再见");
break;
}
}
if(anjian==5)
{
System.out.println ("------------查询功能-------------");
System.out.println ("您的贵卡余额为:"+ye+"元");
System.out.println ("---------------------------------");
int ji;
System.out.println ("是否继续业务:继续:1 取卡:2");
ji=sc.nextInt();
if(ji==1)
{
continue;
}
else
{
System.out.println ("请收回您的磁卡,下次再见");
break;
}
}
if(anjian==0)
{
System.out.println ("请收回您的磁卡,下次再见");
break;
}
}flag=1;
break;
}
}
if(flag==0)
{
System.out.println ("密码输入超过三次,ATM机吞卡");
}
}
}