The web application I am working on needs to be able to handle two different versions of the same PHP extension. (Specifically MapScript for Mapserver 5.6 and MapScript for Mapserver 6.2.)
The script won't know which of the two versions needs to be loaded until after php execution has started. (But only one extension is needed for each request.)
My original plan was to use php built-in dl function, but I discovered that dl has been disabled because of security issues. (http://php.net/manual/en/function.dl.php)
Is there any way secure way to load an extension during execution? Or perhaps always load both, but put them in different namespaces so they can be accessed separately?