I have the issue, too.
I tried putting a random number at the end of the call to openssl_encrypt(), but then I get a boat load of errors about the random number being larger than 0, which is the length expected by the algorithm chosen. So, it sounds like an algorithm is being used that doesn’t need an IV, but in general not using an IV is considered bad, so it throws the original error.