background image

addr=khstr.substring(khstr.indexof("|",numkh)+1,khstr.indexof("|",khstr.indexof("|",numkh)+1)); 
//从 khstr 串中取出与 kh_id 对应的地址字段的值。 

   frm.address.value=addr;  //将取出的值赋给当前录入页面上的字段变量 address。 

</script> 

3.在 html 中将二者结合起来,互为所用 

$khinfo="select kh_id,address from kh where co_id=$s_coid and type='g' order by kh_id"; 

//将取供货商信息的 sql 语句放到变量$khinfo 中。 

  $k=khqk_tq($khinfo);    //调用 php 函数,并将返回的字符串值放到变量$k 中。 

<meta name="generator" content="microsoft developer studio"> 

<meta http-equiv="content-type" content="text/html; charset=gb_2312-80"> 

<title>订货合同管理</title> 

</head> 

<body style="background-color: ivory"> 

<form name=frmplanfill method=post action="dhht_crt.php"> 

  

<table align=center border=1 cellpadding=0 cellspacing=0 width="90%" style="font-size: 10pt"> 

  

  <tr> 

    <td>合同编号</td><td><input name=htbh size=15></td> 

    <td>合同概述</td><td colspan=5><input name=htgs size=53></td> 

  </tr>