|  | 
	                
  
    | 
	 
        รบกวนด้วยคะ ทำการ Search แบบส่งค่า window.open('getData.php?Code='+document.getElementById('Code').value  แล้วส่งค่ากลับไม่ได้นะคะ มันขึ้น Error: null is null or not an object     |  
    |  |  
 
              
  
    | 
 
        
          |  |  |  |  |  
          |  |  | 
            
              | ผมไม่เห็น input id="Code" นะ o.O 
 |  
              | 
                
                  |  |  |  |  
                  |  | 
                      
                        | Date :
                            2014-03-14 22:45:12 | By :
                            itpcc |  |  |  
                  |  |  |  |  |  |  |  
          |  |  |  |  |  
 
        
          |  |  |  |  |  
          |  |  | 
            
              | อันนี้หน้า form คะ Code (PHP)
 
 <?php
include("connect.php");
?>
<html >
<head>
<meta http-equiv="Content-Type" content="text/html; charset=tis-620" />
<title></title>
</head>
<script language="javascript">
	function OpenPopup(intLine)
	{
			window.open('getData.php?Code='+document.getElementById('txtCode').value,'myPopup','width=750,height=500,toolbar=0, menubar=0,location=0,status=1,scrollbars=1,resizable=1,left=0,top=0');
	}
		function CreateNewRow()
	{
		var intLine = parseInt(document.frmMain.hdnMaxLine.value);
		intLine++;
			
		var theTable = document.getElementById("tbExp");
		var newRow = theTable.insertRow(theTable.rows.length)
		newRow.id = newRow.uniqueID
		var newCell
		
		//*** Column No ***//
		newCell = newRow.insertCell(0);
		newCell.id = newCell.uniqueID;
		newCell.setAttribute("className", "css-name");
		newCell.innerHTML = "<center>"+intLine+"</center>";
		//*** Column Code ***//
		newCell = newRow.insertCell(1);
		newCell.id = newCell.uniqueID;
		newCell.setAttribute("className", "css-name");
		newCell.innerHTML = "<center><INPUT TYPE=\"TEXT\" SIZE=\"20\" NAME=\"txtCode[]"+intLine+"\"  ID=\"txtCode"+intLine+"\" VALUE=\"\" +intLine+"\"></center>";
				//*** Column Code ***//
		newCell = newRow.insertCell(2);
		newCell.id = newCell.uniqueID;
		newCell.setAttribute("className", "css-name");
		newCell.innerHTML = "<center><INPUT TYPE=\"TEXT\" SIZE=\"20\" NAME=\"txtName[]"+intLine+"\"  ID=\"txtName"+intLine+"\" VALUE=\"\" +intLine+"\"></center>";
				//*** Column  ***//
		newCell = newRow.insertCell(3);
		newCell.id = newCell.uniqueID;
		newCell.setAttribute("className", "css-name");
		//newCell.setAttribute("OnClick", "OpenPopup('"+intLine+"')");
		newCell.innerHTML = "<center><INPUT TYPE=\"BUTTON\" NAME=\"btnPopup_"+intLine+"\"  ID=\"btnPopup_"+intLine+"\" VALUE=\"..\" OnClick=\"OpenPopup('"+intLine+"')\"></center>";	
		document.frmMain.hdnMaxLine.value = intLine;
	}
	function RemoveRow()
	{
		intLine = parseInt(document.frmMain.hdnMaxLine.value);
		if(parseInt(intLine) > 0)
		{
				theTable = document.getElementById("tbExp");				
				theTableBody = theTable.tBodies[0];
				theTableBody.deleteRow(intLine);
				intLine--;
				document.frmMain.hdnMaxLine.value = intLine;
		}	
	}	
	</script>
<form name="frmMain" method="post"  action="<?=$_SERVER['SCRIPT_NAME'];?>">
		<table width="50%" border="0" id="tbExp"  action="Readdata4">
		  <tr align="center" >
			<td><b>No</b></td>
			<td><b>Code</b></td>
			<td><b>Name</b></td>
			<td><b></b></td>
		  </tr>
		</table>
		<div align="center">
		</div>
			<p>
					<input type="hidden" name="hdnMaxLine" value="0">
					<input name="btnAdd" type="button" id="btnAdd" value="+" onClick="CreateNewRow();">
					<input name="btnDel" type="button" id="btnDel" value="-" onClick="RemoveRow();">
                </table>
				<p></p>
				<div align="center">
						<input type="hidden" name="form"/>
						<input id="saveForm" class="button_text" type="submit" name="submit" value="Submit" />
						<input type="reset" name="Reset" id="button" value="cancel" />
				</div>
                </table>
				</form>	
 |  
              | 
 ประวัติการแก้ไข
 2014-03-14 23:15:19
 
                
                  |  |  |  |  
                  |  | 
                      
                        | Date :
                            2014-03-14 22:56:48 | By :
                            pinkie |  |  |  
                  |  |  |  |  |  |  |  
          |  |  |  |  |  
 
        
          |  |  |  |  |  
          |  |  | 
            
              | ยืนยันคำเดิมครับ ผมไม่เห็น input id="txtCode" นะ
      
 |  
              | 
                
                  |  |  |  |  
                  |  | 
                      
                        | Date :
                            2014-03-14 23:01:50 | By :
                            itpcc |  |  |  
                  |  |  |  |  |  |  |  
          |  |  |  |  |  
 
        
          |  |  |  |  |  
          |  |  | 
            
              | บรรทัดที่ 38 คะ  หนูอยากให้มันส่งค่ามาใส่ textbox สองอันนี้คะ  พอคลิกที่ปุ่ม popup มันจะส่งค่าไป Search ใน file getdata.php  พอได้ค่าแล้ว seldata มันไม่ส่งค่ามาอะคะ  หนูไม่เก่งนะคะ ไม่รู้จะอธิบายพี่เข้าใจหรือเปล่า 
 |  
              | 
                
                  |  |  |  |  
                  |  | 
                      
                        | Date :
                            2014-03-14 23:38:08 | By :
                            pinkie |  |  |  
                  |  |  |  |  |  |  |  
          |  |  |  |  |  
 
 
 
        
          |  |  |  |  |  
          |  |  | 
            
              | ไม่เป็นไรคะ ขอบคุณคะ 
 |  
              | 
                
                  |  |  |  |  
                  |  | 
                      
                        | Date :
                            2014-03-15 15:12:07 | By :
                            pinkie |  |  |  
                  |  |  |  |  |  |  |  
          |  |  |  |  |  
 |  |