Seeing the ghost, $ _ request question. & lt ;? Php $ counter & nbsp; = 0; $ temp & nbsp; = & nbsp; 0; while (! Is_null & nbsp; ($ _ REQUEST [& #39; thisAnswer_id & #39;. & nbsp has a problem with $ _ request.
$ Counter = 0;
$ Temp = 0;
While (! Is_null ($ _ REQUEST ['thisanswer _ id'. ++ $ counter]);
{
+ + $ Temp;
Echo "~~ Temp is ". $ temp ."~~ ";
Echo "~~ Counter is ". $ counter ."~~ ";
$ ThisAnswer_id = array ($ counter = >$ _ REQUEST ['thisanswer _ id'. $ counter]);
?>
The output result is:
~~~ Temp is 1 ~~~
~~~ Counter is 3 ~~~
In addition, if the loop is executed only once, several values will be passed in before.
The purpose of this operation is to receive and store the same values of many attributes transmitted from the previous page in a circular manner into an array.
Please show me what is going on. thank you.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.