You need to stop using isset() all over the place. It is hiding the mistakes you are making in your code. Only use isset() when needed. After the form is submitted, except for unchecked checkboxs and unchecked radio buttons, all the $_POST form fields will be set, even if they are empty. Inside the form processing code, the only place you should use isset() is for checkboxes and radio buttons.
Next, the main point of using functions/classes is to reuse logic so that you can simplify (Keep It Simple-KISS) and eliminate repetition (Don't Repeat Yourself-DRY) in your code. In addition to in the form fields, you have listed most of the field names 8 times in your code, and most of them don't match what the form is using and by throwing isset() statements around them, php is no longer helping you by producing errors for the nonexistent data. You should use the database column names as the form field names and use the same name for the same value throughout your code.
You need to start with just straight-forward form processing code. Once you can write, test, and debug the code you write, you can move onto more advanced programming techniques. Your form processing code should -
1) Detect that a post method form has been submitted.
Note: when uploading files, the total size of the form data can easily exceed the post_max_size setting. If this happens, both the $POST and $FILES arrays will be empty. There are other things that can cause these to be empty, such as invalid markup in the form and uploads being disabled on your server. Your code needs to detect this condition and set up an error message for the user.
You should only store the text of the error message in the error array variable. Any styling should be handled when you display the errors and you should use a css class for the styling so that you don't repeat (DRY) all the styling every time you use it.
2) If your code is responsible for handling more then one form, detect which form has been submitted and also apply any user permissions that are specific to each section of form processing code.
3) Validate the input data. You should set up a separate and specific error messages for each validation test. This will help the user by telling him exactly what is wrong with each piece of data. Other than trimming data, you should not modify it as this changes the meaning of the data. You should only validate the data and decide to either use it not not use it.
4) If there are no validation errors, use the submitted data.
You need to stop creating and closing the database connection around each query. Creating the database connection is a time consuming process, taking 2-3 times longer than running a simple query. Also, when you execute the php code to close the connection, the connection isn't immediately closed, but php won't attempt to reuse it, resulting in each instance of a script creating multiple connections, one for each query that it may be running. Your main application should create the database connection and pass it to any code that needs it.
Persistent connections only work for a very few server configurations, which most web server's don't use, and if you are on a server where they do work, you must set the ATTR_PERSISTENT as part of the connection call. You cannot use the ->setAttribute() method after the connection has been made.
To streamline the form processing code, you can make a single array that defines the form fields and any values the code needs in order to validate and process the data. This will eliminate all the repeated references to the field names and by looping over this defining array to dynamically processing the data, you won't have incorrect fields names floating around in your code, because there won't be any specific logic written out referencing each field name. The defining array would tell the code if the field is required (a non empty value is require), what sort of other validation tests to perform, what sort of CrUD (Create, Update, Delete) operation the field should be used in.