I believe the problem is within the application itself but I don't know why. Let's see if I can explain this...
If I put the query into a barebones .php file. Just the bare minimum to connect and display the results so that they look like they were typed out in notepad the query pulls 251 in 1.56 seconds.
Running the query from the application takes 16.32 seconds for the same 251 records.
The app is using Bootstrap, Jquery, Datatables, etc... The application is going to be rebuilt from the ground up using MySQL. I need to get the existing application faster and stable to last another year+ until the switch over takes place.
The comparison of running the same query on the same server inside versus outside of the application producing a 14.76 second time difference... I don't know if it is capable of repair.