选择关键词
<?php
$result = mysql_query("SELECT id,pid,typename from {$tablepre}type where pid=0 order by id") or die("查询数据库");
while ($row=mysql_fetch_array($result)){ ?>
<script language="JavaScript">
var Info = new Array();
var url = "B.php?pid=<?php echo $row[pid];?>&id=<?php echo $row[id];?>";
var sFeatures = "dialogWidth=600px;dialogHeight=500px;dialogLeft=350;dialogTop=200";
function showDialog(){
//弹出一个showModalDialog,并以returnValue来获取返回值
var returnValue = window.showModalDialog(url,Info,sFeatures);
if(returnValue!=null){
document.all.info.innerHTML=returnValue;
}
}
</script>