Looking at the python code throwing the error, it has to do with finding your calibre configuration directory. I have no idea how php interacts with windows concerning environment vars and the like.
Second-to-last suggestion: write your script in python instead of PHP.
Last suggestion: put your command into a .bat file and have your PHP code exec the bat file. That gives you something to debug, as you can see and set environment variables before calling ebook-convert.exe.
Good luck!
|