Refactoring tbl_addfield.php

I have refactored the tbl_addfield.php according to pear coding standards and modified a if condition so that it is more understandable.