Change like this:
for($i = 0; $i < 3; $i++)
{
if(isset($_POST[$field[$i]]) &&!empty($_POST[$field[$i]])) {
$field[$i] = $_POST[$field[$i]];
}
In your code the loop was like this:
for($i = 0; i > 3; $i++)
In which you forgot to add $ symbol before the the second 'i' in your for loop.
And the second condition was $i > 3
.
You initialized $i as 0 and is checking whether $i is greater than 3, and if it is greater than 3, you increment $i, which is never going to happen as $i is 0 initially.
So it must be $i<3