473,405 Members | 2,261 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

how to rar files unrar through php script

Expand|Select|Wrap|Line Numbers
  1. <?php
  2. $rar_arch = RarArchive::open('', '');
  3. if ($rar_arch === FALSE)
  4.     die("Failed opening file");
  5.  
  6. $entries = $rar_arch->getEntries();
  7. if ($entries === FALSE)
  8.     die("Failed fetching entries");
  9.  
  10. echo "Found " . count($entries) . " ";
  11.  
  12. if (empty($entries))
  13.     die("No valid entries found.");
  14.  
  15. $stream = reset($entries)->getStream();
  16. if ($stream === FALSE)
  17.     die("Failed opening first file");
  18.  
  19. $rar_arch->close();
  20.  
  21. echo "Content of first one follows:\n";
  22. echo stream_get_contents($stream);
  23.  
  24. fclose($stream);
  25. ?> 

Error is:
Fatal error: Class 'RarArchive' not found in C:\Zend\Apache2\htdocs\CSV\email1.php on line 2 .....
Jan 15 '13 #1
0 2080

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Benny | last post by:
Hi, I have written recommend a friend script in ASP which can send a form filled details to around 5 Email Ids at a time. I want people to use this with their custom voice message. Can...
9
by: jab3 | last post by:
So I'm considering a small project that involves online file storage. Let's say I wanted to set up a site that allows people to log-on, create an account, and then have space to upload files. The...
4
by: tb1234 | last post by:
hi i am developing a web based flash application i want to read pdf file using php script. can i read using php fread function? pls Help.... Thanks in advance.
1
by: andrus8 | last post by:
I've never writen any VB Script before and need as much help as i can get with this issue. I need a VB Script that will do the following: open TxtFile1.csv for each line in file save visit...
1
by: sarahmiller | last post by:
Hi I need a script that will send and email with a file/folder, in VB by itself after i click on it, also could a whole folder be sent and would there be a way to make it repeat itself everyday,...
1
KevinADC
by: KevinADC | last post by:
Note: You may skip to the end of the article if all you want is the perl code. Introduction Many websites have a form or a link you can use to download a file. You click a form button or click...
10
by: wanni | last post by:
Hi All, I want to store data in a encypted form (in form of some file) and later on i want to read encrypted data in Java Script and want to pass that encrypted buffer to some Active X component. ...
3
by: littlemaster | last post by:
I have one configuration file. It will be used by perl and shell script. From perl using 'require' I have included the configuration file. Using require, include statement I tried in shell script ,...
1
by: crult | last post by:
Hello, I have a large number of xml files in a folder. I want to read and extract the content of each xml file to a new.txt. I'm only interested in the content having the tag <Texte>, and i want...
3
by: raghusln | last post by:
How to call sequence of batch files from perl script
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.