The Infinite Info

#
How to Add Extra Authentication Field in WordPress Login Page

In order to achieve what you actually want to do, I recommend you use hooks as the best way to edit WordPress as follows