Dynamically loading php exstension without dl() function?

僤鯓⒐⒋嵵緔 提交于 2020-01-11 06:28:06

问题


Is that possible and if it is, how to do that? I'm asking because dl() function is not available to me and because PHP team is abandoning this function from further versions.

Please do not answer "Use the Extension Loading Directives instead" - that is exactly the part which I do not understand how and I would like to/I'm asking about.


回答1:


The function has been removed from all SAPIs other than CLI and Embedded as of PHP 5.3. SAPIs are the interface between PHP and a web server / the CLI / etc.

It is no longer possible to load extensions at run-time in some cases. There are no other options available to you if you find your current SAPI does not support runtime extension loading.

If you need an extension loaded reliably, you should do so in the proper place in the system configuration. No amount of saying "that is not the answer I want" will change reality.



来源:https://stackoverflow.com/questions/13775990/dynamically-loading-php-exstension-without-dl-function

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!