There are always the exec-familiy functions to execute/spawn another process.
As suggested above, you can execute a Prolog interpreter or binary. However, most Prolog implementations also export a C API that can be used to call the Prolog interpreter.
You could create a small PHP module to start an interpreter and execute queries. For instance, the SICStus documentation describes using Prolog from C in detail: