When generating a webapp using yiic tool the site controller has a function that looks like this:
public function actionLogin()
{
...
// collect user input data
if(isset($_POST['LoginForm']))
{
$model->attributes=$_POST['LoginForm'];
...
}
...
}
I think these autogenerated files should use the suggested yii functions to get request variables. I rewrote the function so it looks like this:
public function actionLogin()
{
...
// collect user input data
$request = Yii::app()->request;
if($request->getPost('LoginForm'))
{
$model->attributes=$request->getPost('LoginForm');
...
}
...
}
As a new user I can say that I try to mimic the way the code is written by copying/pasting code that yii already wrote. In this case I started getting all request variebles with $_POST and $_GET and I did not learn until now that there is a better way of doing it.
My suggestion for the next yii release is the change those autogenerated files so that "$request->getPost" is used instead of $_POST, etc…