Oh a fresh install? I believe the problem is not with the script since I've installed/upgraded the script on my dev demo server for many times and never had problem leveling up/clicking adoptables.
Edit:
I visited your site and tested the levelup.php myself on one of your pets. It worked perfectly, as I was able to click it at the first time and then receive an error message when I try to click again:
So yeah, I have no idea why it was being mean to you. XD