ridiculous Posted August 30, 2008 Share Posted August 30, 2008 I'm trying to build a socketed object (.so) that I can dynamically load with the php dl( ) function. My understanding of dynamic php extensions (not compiled into php) is that they are: WINDOWS SERVER => .dll filetype LINUX SERVER => .so filetype My hosting provider will allow me to dynamically load extensions on a linux environment, but I have to compile those extensions first. -I don't have shell access. -I have the extension source code(s) from php.net -I want to compile the extension source code into a .so (or download the .so from somewhere) and drop it into a directory in my hosting account so that (from there) I can dynamically load it. Questions: [1] Do you have to compile a php extension from the same linux distribution environment that you are going to run it in? [2] Is there any way to compile a .so file from Windows XP? [3] Does anyone know where I can download the: [3a] sockets.so [3b] imap.so extensions (already compiled)? /All feedback is welcome. Even smartass remarks. Just be funny. Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 30, 2008 Share Posted August 30, 2008 First of all, dl() is horribly slow. Second of all, what kind of extension are you writing that you need to compile anyway...? I know on my linux box, I just run: cd /home/nick/php_builds/current/ext/ext_name phpize ./configure --enable-ext_name make And then there is a .so in the modules directory of the ext_name directory. Quote Link to comment Share on other sites More sharing options...
ridiculous Posted August 30, 2008 Author Share Posted August 30, 2008 -I'm not writing an extension, I'm just trying to include imap.so and sockets.so - both of which should be standard but which goDaddy has opted not to compile into php. -I don't have command line access like you do, so that won't work for me. Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 30, 2008 Share Posted August 30, 2008 Don't use GoDaddy then. There's plenty of hosts that offer so much more for reasonable prices. Your scripts WILL suffer time-wise if you have to use dl(). Quote Link to comment Share on other sites More sharing options...
ridiculous Posted August 30, 2008 Author Share Posted August 30, 2008 What about just calling the extension in php.ini...like documented here http://us2.php.net/manual/en/ini.core.php#ini.extension [1] Is that slow also? [2] Who do you think is a better hosting company than goDaddy? I pay about $6 a month for shared hosting. Quote Link to comment Share on other sites More sharing options...
DarkWater Posted August 30, 2008 Share Posted August 30, 2008 What about just calling the extension in php.ini...like documented here http://us2.php.net/manual/en/ini.core.php#ini.extension [1] Is that slow also? [2] Who do you think is a better hosting company than goDaddy? I pay about $6 a month for shared hosting. 1) Doubt you can actually enable them in your php.ini on the shared hosting. 2) I like bluehost.com and hostgator.com, actually. I like the former more than the latter though. 3) The best option is a dedicated server though. *shifty eyes* Quote Link to comment Share on other sites More sharing options...
ridiculous Posted August 30, 2008 Author Share Posted August 30, 2008 Well, they tell me that I can install any extensions that I want...I just have to turn them on in the php.ini file and specify a file path. The problem is that I have to build them first, and I'm under the impression that I have to build the .so on the system its going to run on. Quote Link to comment Share on other sites More sharing options...
ridiculous Posted August 30, 2008 Author Share Posted August 30, 2008 come now. talk to me, people. Quote Link to comment Share on other sites More sharing options...
toplay Posted August 30, 2008 Share Posted August 30, 2008 You should state the bottom line of what you're trying to do. For instance, you can use fsockopen() or perhaps cURL instead (if available) of trying to install sockets.so. I doubt you can do what you want through godaddy (they're very limiting with their PHP). They're a great registrar, but I would never use them to host a web site. FYI: I highly recommend to host with these guys (starting at $4.95 USD): http://www.ixwebhosting.com/index.php/v2/pages.planBusinessPlus Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.