in the yii documentation it says:
foreach($_POST['LoginForm'] as $name=>$value)
{
if($name is a safe attribute)
$model->$name=$value;
}
what does the array LoginForm come from? which attribute is it coupled to?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
In PHP, $_POST contains the input fields ‘posted’ from an HTML form.
In an HTML form, items have names
So when PHP provides this input to the script it makes the input into an array by the names, which you can iterator over with the foreach.