Can I do something like this?
$captcha_results = $_REQUEST[$_REQUEST['field_name']];
I am interested in it, because I try to find out where I've made a mistake. Thank you in advance.
Yes, of course. The one you've just asked is one of variable variables. You can learn more the PHP variables here:
For example, you have $var
containing value of foobar
. You can use the value for other references (in my case, as an index of an array), as shown below.
$var = 'foobar';
$array['foobar'] = 'bar';
echo $array[$var];
This will output bar
as a result.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.