当前位置:编程学习 > JAVA >>

求高手指点 页面链接不对 还找不到那的错误

这是页面代码    

<html><head>

<meta http-equiv="Content-Type" content="text/html; charset=jbk" />
<title>用户管理</title>
<link type="text/css" rel="stylesheet" href="css/style.css">
<script type="text/javascript">
function doit(id)
{

//使用js的页面跳转来实现数据传送
window.location.href="UpateServlet?id"=id;
}
</script>
</head><body>


<div class="menu">

<table>
<tbody><tr><td><form method="post" action="ChaXunServlet">
<input name="flag" value="search" class="input-text" type="hidden">
用户名称:<input name="userName" class="input-text" type="text">     <input value="查 询" type="submit">
</form></td></tr>
</tbody></table>
</div>
<div class="main">

<div class="optitle clearfix">
<em><input value="添加数据" class="input-button" onclick="window.location='userAdd.jsp'" type="button"></em>
<div class="title">用户管理>></div>
</div>
<div class="content">
<table class="list">
  <tbody><tr>
    <td width="70" height="29"><div class="STYLE1" align="center">编号</div></td>
    <td width="80"><div class="STYLE1" align="center">用户名称</div></td>
    <td width="100"><div class="STYLE1" align="center">密码</div></td>

  </tr>
   <!--servlet里的list-->
  
  
 <tr>
    <td height="23"><span class="STYLE1">2</span></td>
    <td><span class="STYLE1"><a href="UpdateServlet?id=2 ">zhoupan</a></span></td>

    <td><span class="STYLE1">zhoupan</span></td>

   </tr>
  
  
 <tr>
    <td height="23"><span class="STYLE1">1</span></td>
    <td><span class="STYLE1"><a href="UpdateServlet?id=1 ">AWREAW</a></span></td>

    <td><span class="STYLE1">ASEDA</span></td>

   </tr>
  
  
  
</tbody></table>
</div>
</div>
</html>

点上面查询的时候就会出现下面的      应该这个页面是点供应商时出来的


<html xmlns="http://www.w3.org/1999/xhtml">
<meta http-equiv="Content-Type" content="text/html; charset=gbk" />
<title>供应商查询</title>
<link type="text/css" rel="stylesheet" href="css/style.css">
<script type="text/javascript">
function doit(flag,id)
{

window.location.href="UpateServlet?id"=id;
}
</script>
</head>
<body>
<div class="menu">

<table>
<tbody><tr><td><form method="post" action="provider.jsp">
<input name="flag" value="search" type="hidden">
供应商名称:<input name="providerName" class="input-text" type="text">     供应商描述:<input name="providerDesc" class="input-text" type="text">    <input value="组 合 查 询" type="submit">
</form></td></tr>
</tbody></table>
</div>
<div class="main">
<div class="optitle clearfix">
<em><input value="添加数据" class="input-button" onclick="window.location='providerAdd.jsp'" type="button"></em>
<div class="title">供应商管理>></div>
</div>

<div class="content">
<table class="list">
  <tbody><tr>
    <td width="70" height="29"><div class="STYLE1" align="center">编号</div></td>
    <td width="80"><div class="STYLE1" align="center">供应商名称</div></td>
    <td width="100"><div class="STYLE1" align="center">供应商描述</div></td>

  </tr>
  <!--servlet里的list-->
  
  
 <tr>
    <td height="23"><span class="STYLE1">1</span></td>
    <td><span class="STYLE1"><a href="UpdateServlet?id=1 ">xiao</a></span></td>

    <td><span class="STYLE1">ma</span></td>

   </tr>
  
  
 <tr>
    <td height="23"><span class="STYLE1">2</span></td>
    <td><span class="STYLE1"><a href="UpdateServlet?id=2 ">mam</a></span></td>

    <td><span class="STYLE1">en</span></td>

   </tr>
  
  
  
</tbody></table>
</div>
</div>
</body></html>
--------------------编程问答-------------------- window.location.href="UpateServlet?id"=id;
改为
window.location.href="UpateServlet?id="+id;
试试! --------------------编程问答-------------------- 已经解决了       谢了 
补充:Java ,  非技术区
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,