PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
anjanesh
DevNet Resident
Posts: 1679 Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India
Post
by anjanesh » Sun Jun 11, 2006 2:55 pm
Hi
Is there anyway to uload an extension during run-time ?
Code: Select all
if (extension_loaded('someext'))
{
u_dl('php_someext.dll'); # Unload php_someext.dll
}
Is this possible ?
Thanks
derchris
Forum Commoner
Posts: 44 Joined: Sat Jun 10, 2006 6:14 pm
Post
by derchris » Sun Jun 11, 2006 3:39 pm
No,
extensions can only be disabled by editing php.ini
anjanesh
DevNet Resident
Posts: 1679 Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India
Post
by anjanesh » Sun Jun 11, 2006 11:53 pm
No way to unload it using ini_set ?
Code: Select all
<?php
ini_set('extension', 'php_curl.dll'); # Need the opposite of this - make it to #extension or something
phpinfo();
?>
derchris
Forum Commoner
Posts: 44 Joined: Sat Jun 10, 2006 6:14 pm
Post
by derchris » Mon Jun 12, 2006 3:39 am
Only if the extension has an attribute for that.
Like:
extension.bla_enabled = 0/1 in php.ini
Then you can set it in runtime by:
Code: Select all
ini_set("extension.bla_enabled", "0");
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Mon Jun 12, 2006 11:37 am
that I know of, that will not actually unload the extension, per se, but just tell it not to process.
twigletmac
Her Royal Site Adminness
Posts: 5371 Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK
Post
by twigletmac » Mon Jun 12, 2006 4:23 pm
Just out of interest, why are you trying to unload an extension?
Mac
anjanesh
DevNet Resident
Posts: 1679 Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India
Post
by anjanesh » Mon Jun 12, 2006 11:05 pm
Need to get mod_gzip to stop working so that flush() works.
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Mon Jun 12, 2006 11:52 pm
mod_gzip is an apache module. Do you mean
ob_gzhandler() ? If so, look at the notes found on the linked page.