as you can see, there are repeated things in the source code.
create a function which can make a textfield,
make a function which can make a dropdown list with the 0-5 list, and the form elamant variable would be the primaryKEy number from the database.
lets create 3 database tables where you need to store these:
personal_information: personal_info_ID , name, ect...
vote_questions: vote_question_ID , title , order
answers (it has 4 fields: answer_ID, personal_info_ID , vote_question_ID, user_IP)
Connect to the database,
when you build the lists you read the questions from the database.
On the process page , you reach the inserted information with a $_POST superglobal (array)