Zipper
Zipper copied to clipboard
Zipper does not create real directories?
Hello,
I have noticed that directories are not created on my archive. The files does contain the path in their name, so in the most cases operating software can manage this, but not always.
For instance, my almost correct ZIP created with Zipper:

And a correct ZIP file:

Please notice that in the first case, there is no single line like js or fonts whereas there are present in the second case.
Here is my code:
$zipper = new \Chumper\Zipper\Zipper;
$zipper->make(public_path().'/medias/'.$equipment->outlet->company_id.'/'.$name)
->addString('index.html', $output);
if(is_dir(app_path().'/views/templates/'.$theme.'_assets')) {
$zipper->add(app_path().'/views/templates/'.$theme.'_assets');
}
$zipper->close();
Am I doing something wrong?
I have tried to use folder() and a loop, but with no results.
I am also facing the same issue. It makes all the files in sub-folders to root level