Retrieve data from layout

Hello,

I’d would like to ask an easy and fast question because I’ve been searching for 2 days now and can’t find a solution.

If I have a form in the layout/main.php (login form), how and where can I process its data?

layout/main.php:

I mean, as you can see there is the attribute action="/prova/index.php/login" because I would like to capture an process the data in my LoginController, but I print POST ( print_r($_POST); ) and its empty.

Any help would be appreciated.

Thanks in advance.

It’s because you have no name attributes into inputs.




<form action="/prova/index.php/login" method="POST" name="LoginForm">

<input class="input-small" type="text" placeholder="Email" name="Email">

<input class="input-small" type="password" placeholder="Password" name="Password">

<button class="btn" type="submit">Login</button>

</form>



/* moved - not specific to Yii */