CodeMaster2 Posted May 19, 2007 Share Posted May 19, 2007 I am working on an application to Rar and UnRar files, the latter of which is possible through native PHP functions, but the Raring (compressing/arching/packing/creating) isn't. I know that the same program that allows for UnRaring is available, but for some reason is not implemented already in PHP. Unfortunately, I lack the skill and the know-how to integrate a program with a PHP script, much less in Linux, an OS I have little experience in. Any help would be very appreciated. Links: Rarlabs: http://rarlabs.com/download.htm PHP Classes compression class (Windows only): http://www.phpclasses.org/browse/package/3556.html PHP native RAR functions: http://www.php.net/rar Quote Link to comment https://forums.phpfreaks.com/topic/52161-phplinux-rar-files-linux-and-php/ Share on other sites More sharing options...
hitman6003 Posted May 20, 2007 Share Posted May 20, 2007 It's already been done.......... http://www.phpclasses.org/browse/package/3556.html Quote Link to comment https://forums.phpfreaks.com/topic/52161-phplinux-rar-files-linux-and-php/#findComment-257320 Share on other sites More sharing options...
CodeMaster2 Posted May 20, 2007 Author Share Posted May 20, 2007 Yes, it has... For windows. If you take a look at that source code you'll see that you need to have WinRAR.exe for it to function. Unfortunately, even though there is a Linux version, the author of that code didn't include implementation of it - which incidentally is what I'm looking for. Quote Link to comment https://forums.phpfreaks.com/topic/52161-phplinux-rar-files-linux-and-php/#findComment-257402 Share on other sites More sharing options...
hitman6003 Posted May 20, 2007 Share Posted May 20, 2007 The only thing that class does is run some commands via the exec function...which should be platform independent. Once you install rar to your linux server, then you simply change the variable in the class to point to the executable. You will either need to find some binaries for your linux distro, or get the source from rar labs and compile it. Then it should work fine. I believe the reason that you can not compress to rar with the pecl library is because you must purchase a license for the rar software. Quote Link to comment https://forums.phpfreaks.com/topic/52161-phplinux-rar-files-linux-and-php/#findComment-257614 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.