Code has to be executed for each iteration of the loop
This file should not end in .lib.php
Remove author name
Fix typos
Fix typo