Lines Matching +full:- +full:- +full:debug

16         $this->functions = $functions;
19 $this->pdfGenerator = new siteexport_pdfgenerator($functions);
25 return $this->pdfGenerator !== null;
37 …$tmpFile = tempnam($this->functions->settings->tmpDir, 'siteexport__') ?: $this->functions->settin…
45 $status = $this->__writeFileToZip($tmpFile, $FILENAME, $ZIP);
47 $status = $this->__addFileToZip($tmpFile, $FILENAME, $ZIP);
59 * @param $FILE String file-name of the zip
66 …$this->functions->debug->message("Weird, the NAME for the ZIP started with a '/'. This may result …
71 if ($this->canDoPDF()) {
72 …$this->functions->debug->message("Trying to create PDF from File '$FILE' with name '$NAME' for ZIP…
74 $succeeded = $this->pdfGenerator->createPDFFromFile($FILE, $NAME);
76 …if ($this->functions->debug->debugLevel() <= 1) { // 2011-01-12 Write HTML to ZIP for Debug purpose
77 $this->__moveDataToZip($succeeded, "_debug/$NAME.html", $ZIP, true);
81 …$this->functions->debug->runtimeException("Create PDF from File '$FILE' with name '$NAME' went wro…
86 return $this->__writeFileToZip($FILE, $NAME, $ZIP);
90 * This really writes a file to a zip-file
91 * @param $FILE String file-name of the zip
96 if (empty($ZIPFILE)) $ZIPFILE = $this->functions->settings->zipFile;
99 …$this->functions->debug->runtimeException("PHP class 'ZipArchive' does not exist. Please make sure…
105 …$this->functions->debug->runtimeException("Can't create new instance of 'ZipArchive'. Please make …
109 $code = $zip->open($ZIPFILE, \ZipArchive::CREATE);
112 $this->functions->debug->message("Adding file '{$NAME}' to ZIP {$ZIPFILE}", null, 2);
114 $zip->addFile($FILE, $NAME);
115 $zip->close();
119 // ALibi Touching - 2011-09-13 wird nicht gebraucht nach Umstellung
124 $this->functions->debug->runtimeException("Zip Error #{$code} for file {$NAME}");
135 $code = $zip->open($this->functions->settings->zipFile, \ZipArchive::CREATE);
137 $exists = !($zip->statName($NAME) === FALSE);
138 $zip->close();
151 $pattern = $this->functions->requestParametersToCacheHash($requestData);
152 return $this->hasValidCacheFileForPattern($pattern, $depends);
157 $this->functions->debug->message("HASH-Pattern for CacheFile: ", $pattern, 2);
158 $this->functions->settings->hasValidCacheFile = false; // reset the cache settings
159 $cacheFile = $this->functions->getCacheFileNameForPattern($pattern);
163 // Check if the file is expired - if so, just create a new one.
164 if ($mtime == 0 || $mtime < time()-$this->functions->settings->cachetime)
166 $this->__clearCacheFile( $cacheFile );
167 …$this->functions->debug->message("New CacheFile because the file was over the cachetime: ", $cache…
174 $this->functions->debug->message("Checking dependencies: ", $depends, 1);
179 $this->functions->debug->message("File does not exist: ", $site['id'], 2);
184 $this->__clearCacheFile( $cacheFile );
185 … $this->functions->debug->message("New CacheFile, because a page changed: ", $cacheFile, 2);
191 $this->functions->debug->message("CacheFile exists: ", $cacheFile, 2);
192 return $this->functions->settings->hasValidCacheFile = true;
197 @unlink($this->functions->settings->zipFile) === false ) {
198 $this->functions->debug->message("Cannot remove cache Files: ", $cacheFile, 2);
204 if (is_null($data['file'])) $data['file'] = $this->functions->settings->zipFile;
207 $code = $zip->open($data['file']);
209 $this->functions->debug->message("Can't open the zip-file.", $data['file'], 2);
213 if ($zip->numFiles != 1) {
214 $zip->close();
215 …$this->functions->debug->message("More than one ({$zip->numFiles}) file in zip.", $data['file'], 2…
219 $stat = $zip->statIndex(0);
220 $this->functions->debug->message("Stat.", $stat, 3);
221 if (substr($stat['name'], -3) != 'pdf') {
222 $zip->close();
223 … $this->functions->debug->message("The file was not a PDF ({$stat['name']}).", $stat['name'], 2);
233 $zip->extractTo($folder, $stat['name']);
234 $zip->close();