作者LPH66 (亨ちゃんは可爱い>/////<)
看板PHP
标题Re: [请益] 有关$_GET[]函数...
时间Tue May 9 20:14:49 2006
※ 引述《lightskyor (Alien)》之铭言:
: 请问大家一个问题,在PHP中若要读取前一网页中的form选单中的资料,可利用
: $_GET['name']来使用(在method=get之下)
: 这个「name」是前一个网页(a.htm)的变数名称,
: 那请问,如果在处理的程式中(b.php),若想要利用一个变数来代替name,
: ex.$temp=name
: 是否可以利用$_GET[' ']结合$temp的方式将前一网页的资料读取出来呢?
: 请解益,谢谢^^
sample:
<?php
$var=1;
$name="var";
$q=$$name;
$r=${$name};
echo "${$name},$q,$r";
?>
output:
1,1,1
--
'Oh, Harry, dont't you
see?' Hermione breathed. 'If she could have done
one thing to make
absolutely sure that every single person in this school
will read your interview, it was
banning it!'
---'Harry Potter and the order of the phoenix', P513
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.112.30.84