Solved

Add password on Zip via PHP

Posted on 2008-06-16
7
415 Views
Last Modified: 2012-06-27
i tried this suggestion: http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/PHP/Q_22848474.html

But, it didn't worked. What should i try :/
0
Comment
Question by:springfresh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 48

Expert Comment

by:hernst42
ID: 21800383
what does not work with that solution?
which OS is the webserver running?
0
 

Author Comment

by:springfresh
ID: 21800393
i am running on windows. I i am installed WAMP server on windows VISTA
0
 
LVL 48

Expert Comment

by:hernst42
ID: 21800416
zip must be in the PATH and the webserver must be able to write to the directory where WAMP is running.
Check your permissions and pathes.
0
Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

 

Author Comment

by:springfresh
ID: 21800469
well, i am doing like that:
And it creates .zip file, but do not add password :/
$zip = new ZipArchive();
$filename = $username.'-'.$date.'-'.$random.'.zip';
 
if ($zip->open($filename, ZIPARCHIVE::CREATE)!==TRUE) {
}
 
$zip->addFromString($date."-textfile.txt", "Works!\n");
echo system('zip -P bla '.$filename);
$zip->close();

Open in new window

0
 

Author Comment

by:springfresh
ID: 21800641
hm, aha i see now, that i need zip.exe in that dir. But where can i download free version. I tried from http://www.info-zip.org/Zip.html#Win32 . But i dont know which one should i download. I am using windows Vista
0
 
LVL 48

Accepted Solution

by:
hernst42 earned 500 total points
ID: 21801008
don't know a about a free version. I use seven zip, but can't find the link
0
 

Author Closing Comment

by:springfresh
ID: 31467869
thanks, worked!
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

These days socially coordinated efforts have turned into a critical requirement for enterprises.
This article discusses four methods for overlaying images in a container on a web page
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question