php中,我想在地址栏输入:"http://localhost/index.php?=100"网页正文就显示"100" 如果将100改成其它字符,网页正文也跟着改变,这个应该怎样写? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 echo substr($_SERVER["QUERY_STRING"], 1); http://localhost/index.php?page=100&用JS提交var xmlHttp1112function showUser219(){ xmlHttp1112=GetXmlHttpObject1112()if (xmlHttp1112==null) { alert ("Browser does not support HTTP Request") return }var url1="indexbs219.php"var getnam=100url1=url1+"?p="+getnamurl1=url1+"&sid="+Math.random()xmlHttp1112.onreadystatechange=stateChanged1112 xmlHttp1112.open("GET",url1,true)xmlHttp1112.send(null)}function stateChanged1112() { if (xmlHttp1112.readyState==4 || xmlHttp1112.readyState=="complete") { document.getElementById("content1").innerHTML=xmlHttp1112.responseText } }function GetXmlHttpObject1112(){var xmlHttp1112=null;try { // Firefox, Opera 8.0+, Safari xmlHttp1112=new XMLHttpRequest(); }catch (e) { //Internet Explorer try { xmlHttp1112=new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { xmlHttp1112=new ActiveXObject("Microsoft.XMLHTTP"); } }return xmlHttp1112;}==========================<head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>tranfor</title></head><?php$con = mysql_connect("localhost","root","888888");if (!$con) { die('Could not connect: ' . mysql_error()); }mysql_query("set names gb2312");$getflowid=$_GET["p"]; $getnampc=$_GET["qa"]; $getnamhs=$_GET["qb"]; $getvalpc=$_GET["qc"];$getunitpc=$_GET["qd"]; $getmaospc1=$_GET["qe"];获取变量并使用 例如:http://localhost/index.php?id=100在index.php页面加入if(isset($_GET['id'])){ $id=$_GET['id']; //这个id应该是作为数据库里面某个表的primary key,根据这个id来调用数据库里的数据,然后显示数来 echo $id;} 很久没上了发现帐号密码错误,然后找回密码发现EMAIL不是我的,重新注册,没有发帖子权限,愁死!我也想实现这个效果不知道怎么操作我想在一个页面调用该页面的ID 如下:http://localhost/download.php?id=234在这个页面调用234不知道用PHP如何调用比如<!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=gb2312" /><title></title></head><table width="600" border="1" align="center" cellpadding="10" cellspacing="0" bordercolor="#FF0000"> <tr> <td>在这里调用ID</td> </tr></table><body></body></html>知道的说下,最好详细点,比较菜,谢谢了! 大家帮我看下为什么报错呢!!! 最近遇到个比较诡异的问题,麻烦大家帮忙看下,有哪里遇到过,谢谢 如何利用正则表达式来搜索Mysql数据库 redhat的 mysql的安装包rpm在哪里得到 求助一个PHP问题! 新手想看本入门的书 问一个 function 中 if 语句的问题,本人菜鸟一个 比较郁闷,遇贼。分享一个好东东,顺便散分 如何在页面传递数组?高手请指点,在线等,急!!! 为什么ie可以正常接收到js生成的表单内容,chrome却不行 PHP的用户认证 手机登陆网站如何获取手机操作系统及手机型号??
echo substr($_SERVER["QUERY_STRING"], 1);
用JS提交
var xmlHttp1112
function showUser219()
{
xmlHttp1112=GetXmlHttpObject1112()
if (xmlHttp1112==null)
{
alert ("Browser does not support HTTP Request")
return
}var url1="indexbs219.php"
var getnam=100
url1=url1+"?p="+getnam
url1=url1+"&sid="+Math.random()
xmlHttp1112.onreadystatechange=stateChanged1112
xmlHttp1112.open("GET",url1,true)
xmlHttp1112.send(null)
}function stateChanged1112()
{
if (xmlHttp1112.readyState==4 || xmlHttp1112.readyState=="complete")
{
document.getElementById("content1").innerHTML=xmlHttp1112.responseText
}
}function GetXmlHttpObject1112()
{
var xmlHttp1112=null;
try
{
// Firefox, Opera 8.0+, Safari
xmlHttp1112=new XMLHttpRequest();
}
catch (e)
{
//Internet Explorer
try
{
xmlHttp1112=new ActiveXObject("Msxml2.XMLHTTP");
}
catch (e)
{
xmlHttp1112=new ActiveXObject("Microsoft.XMLHTTP");
}
}
return xmlHttp1112;
}
==========================
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>tranfor</title>
</head><?php
$con = mysql_connect("localhost","root","888888");if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_query("set names gb2312");
$getflowid=$_GET["p"];
$getnampc=$_GET["qa"];
$getnamhs=$_GET["qb"];
$getvalpc=$_GET["qc"];
$getunitpc=$_GET["qd"];
$getmaospc1=$_GET["qe"];
获取变量并使用
http://localhost/index.php?id=100在index.php页面加入if(isset($_GET['id']))
{
$id=$_GET['id'];
//这个id应该是作为数据库里面某个表的primary key,根据这个id来调用数据库里的数据,然后显示数来
echo $id;
}
<!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=gb2312" />
<title></title>
</head>
<table width="600" border="1" align="center" cellpadding="10" cellspacing="0" bordercolor="#FF0000">
<tr>
<td>在这里调用ID</td>
</tr>
</table>
<body>
</body>
</html>知道的说下,最好详细点,比较菜,谢谢了!