if ($without_files = $this->getdata("without_files", "none")) { $ARCurrent->options["without_files"] = true; } if ($force = $this->getdata("force", "none")) { $ARCurrent->options["force"] = true; } $source = $this->store->get_config("files") . "temp/" . $file["source_temp"]; $ax_config["writeable"] = false; $ax_config["database"] = $source; set_time_limit(0); $store = new axstore("", $ax_config); if (!$store->error) { $ARCurrent->importStore =& $this->store; // srcpath and destpath may be empty $callArgs = array("srcpath" => $srcpath, "destpath" => $this->path); $store->call("system.export.phtml", $callArgs, $store->get("/")); $error = $store->error; $store->close(); } else { $error = "import error: " . $store->error; } unlink($source); } else { $error = "import error: '{$source}' could not find uploaded file. (does the filesize exceed the maximum upload size?)"; } if ($error) { echo $error . "\n"; } ?> <?php }
</div> <div id="progress_verbose"></div> <?php foreach ($sources as $key => $srcpath) { echo "<script type='text/javascript'>currentProgressBar = '{$key}';</script>"; $sourceob = current($this->get($srcpath, "system.get.phtml")); if ($full_path) { $destpath = ""; } else { if ($sourceob->parent == "..") { $destpath = "/"; } else { $destpath = "/" . substr($sourceob->path, strlen($sourceob->parent)); } } if (!$importStore->error) { $callArgs = array("srcpath" => $srcpath, "destpath" => $destpath); $error = $this->call("system.export.phtml", $callArgs); } else { $error = "ax error: " . $importStore->error; } if ($error) { echo $error . "\n"; } if ($error) { // prevent js download code from running echo "<script type='text/javascript'> error=true; </script>"; } } $importStore->close(); // }