PDA

View Full Version : سوال: انتقال اطلاعات به پنجره popup



nimja145
جمعه 28 مرداد 1390, 21:24 عصر
سلام دوستان
من از کد زیر برای بازکردن پنجر popup استفاده میکنم.;که توسط یکی از دوستان داخل همین انجمن نوشته شده بود.

فایل index:



<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<script type="text/javascript">
var popup;
function Popup() {
popup = window.open("pop.php", "popup_id",
"scrollbars,resizable,width=300,height=400");
popup.document.getElementById('popuptxt').value=do cument.getElementById('txt').value;
return (false);
}
</script>
</head>
<body>
asas
<br />
<form name="frm" >
<input name="txt" type="text" value="main" id="txt"><br />
<input type=submit value=ss onclick="return Popup()" />
</form>
</body>
</html>



فایل pop.php




html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Popup</title>
</head>
<body>
<form action=pop.htm>
<input name="txt" type="text" value="main" id="popuptxt"><br />
<input type=submit value="??????" style="font-family:Tahoma;" />
</form>
</body>
</html>



چطور میتونم مقدار txt داخل یک متغیر php بریزم؟