Interface for using spidermonkey in PHP