Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

php, zip datei auf dem server ablegen OHNE "speichern unter"

Empfohlene Antworten

Veröffentlicht

hallo an alle, ich bin neu hier und habe auch gleich mein grosses problem zu verkünden...

ich möchte gerne den "speichern unter" dialog umgehen und eine datei (ZIP) auf dem Server ablegen....der Zielort soll meinetwegen im php script erzeugt oder schon vorhanden sein... kann mir jemand da input geben??? wäre super...

ich probiere schon seit längerem die zip.lib zu modifizieren jedoch klappt das nicht....angehängt mal die zip.lib und hier dessen aufruf...

require('./zip.lib.php');

//Generate a new object
$zipfile = new zipfile('archive.zip','./DeepDir.php', './extendedfpdf.php');

//Add a complete dir (recursiv)
$zipfile->addDirContent('./');

//Add a single file
$zipfile->addFileAndRead('testfiles/picture.jpg');

//Output the new zip file
echo $zipfile->file();[/PHP]

eine andere zip bib macht ungefähr das was ich will...aber ich möcht den "speichern unter" dialog nicht haben. er soll mir einfach das in ein verzeichnis auf dem server packen....

der aufruf der anderen zip.lib2 sieht so aus...

[PHP]require('zip.lib2.php');

$zipfile = new zipfile();

// add the subdirectory ... important!
$zipfile -> add_dir("e_lesson/");

// add the binary data stored in the string 'filedata'
$filedata = "(read your file into $filedata)";
$zipfile -> add_file($filedata, "e_lesson/file.txt");

// the next three lines force an immediate download of the zip file:
header("Content-type: application/octet-stream");
header("Content-disposition: attachment; filename=e_lesson.zip");
echo $zipfile -> file();

.

kann mir da jemand helfen....danke im voraus bye bye crunny...

ziplib-2003-04-14.rar

Hi,

dein Vorhaben sollte mit dem FILE_ARCHIV von http://pear.php.net sehr einfach umzusetzen zu gehen.

Gruß,

Markus

Ich verstehe ehrlich gesagt nicht was Du willst...

Auf welchem Server willst Du die Datei direkt ablegen? Meinst Du nicht eher den Client?

Oder willst Du das, was der Client als Download angeboten bekommt, auf dem Webserver in ein Verzeichnis legen?

er will eine ZIp erzeugen anhand von Daten auf dem Server und die Zip auf dem Server ablegen..

hab ein Script mit dem das geht, suche es morgen mal raus :)

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.