Lines Matching full:if

25  * @return bool - true if at least one namespace was deleted
43 if (@rmdir($dir)) {
44 if ($ns_type !== false) {
65 …* $data[1] ns: The colon separated namespace path minus the trailing page name. (false if root …
78 if (empty($rev)) {
95 if (is_array($data) && is_array($data[0]) && count($data[0]) === 2) {
105 * Uses gzip if extension is .gz
107 * If you want to use the returned value in unserialize
120 if (file_exists($file)) {
121 if (str_ends_with($file, '.gz')) {
122 if (!DOKU_HAS_GZIP) return false;
124 if (is_array($ret)) {
128 if (!DOKU_HAS_BZIP) return false;
134 if ($ret === null) return false;
135 if ($ret !== false && $clean) {
155 if ($bz === false) return false;
157 if ($array) {
164 if (($buffer === false) || (bzerrno($bz) !== 0)) {
168 if ($array) {
178 if ($array) {
179 if ($str !== '') {
197 …* $data[1] ns: The colon separated namespace path minus the trailing page name. (false if root …
211 if (empty($rev)) {
214 if ($rev === false) {
231 if (is_array($data) && is_array($data[0]) && count($data[0]) === 3) {
234 if ($ok && is_int($data[3]) && $data[3] > 0) {
259 if (str_ends_with($file, '.gz')) {
260 if (!DOKU_HAS_GZIP) return false;
262 if (!$fh) return false;
266 if (!DOKU_HAS_BZIP) return false;
267 if ($append) {
269 if ($bzcontent === false) return false;
273 if (!$fh) return false;
278 if (!$fh) return false;
283 if (!$fileexists && $conf['fperm']) {
292 * If the third parameter is set to true the given content
295 * Uses gzip if extension is .gz
296 * and bz2 if extension is .bz2
309 if (!_io_saveFile($file, $content, $append)) {
326 * or all lines if $maxlines is -1. If $regex is true then captures can be used in $newline.
330 * Uses gzip if extension is .gz
331 * and bz2 if extension is .bz2
346 if ((string)$oldline === '') {
351 if (!file_exists($file)) return true;
356 if (str_ends_with($file, '.gz')) {
357 if (!DOKU_HAS_GZIP) return false;
360 if (!DOKU_HAS_BZIP) return false;
371 if ($maxlines > 0) {
375 if ($count >= $maxlines) break;
378 if ($matched) {
384 if ((string)$newline !== '') {
391 if (count($lines)) {
392 if (!_io_saveFile($file, implode('', $lines), false)) {
445 if ((time() - $timeStart) > 3) break;
447 if ($locked) {
448 if ($conf['dperm']) {
490 if (!isset($types[$ns_type])) {
502 if (strlen($ns) == 0) {
528 if (!@is_dir($dir)) {
529 if (!io_mkdir_p($dir)) {
548 if (@is_dir($target) || empty($target)) return true; // best case check first
549 if (file_exists($target) && !is_dir($target)) return false;
551 if (io_mkdir_p(substr($target, 0, strrpos($target, '/')))) {
553 if ($ret && !empty($conf['dperm'])) {
572 if (!is_string($path) || $path == "") return false;
573 if (!file_exists($path)) return true; // it's already gone or was never there, count as success
575 if (is_dir($path) && !is_link($path)) {
578 if (!$dh = @opendir($path)) return false;
580 if ($f == '..' || $f == '.') continue;
583 if (is_dir("$path/$f") && !is_link("$path/$f")) {
594 if (!io_rmdir($dir, $removefiles)) return false; // abort on any error
598 if (!@unlink($file)) return false; //abort on any error
625 if (io_mkdir_p($tmpdir)) {
635 * if $useAttachment is false,
637 * - if successful will return true, false otherwise
639 * if $useAttachment is true,
641 * - if successful will return the name used for the saved file, false otherwise
647 * @param string $defaultName fallback for if using $useAttachment
649 …* @return bool|string if failed false, otherwise true or the name of the file in the give…
663 if (!$data) return false;
666 if ($useAttachment) {
667 if (isset($http->resp_headers['content-disposition'])) {
670 if (
678 if (!$name) {
679 if (!$defaultName) return false;
688 if (!$fp) return false;
691 if (!$fileexists && $conf['fperm']) {
694 if ($useAttachment) return $name;
711 if (!@rename($from, $to)) {
712 if (@copy($from, $to)) {
713 if ($conf['fperm']) {
743 if (!$ph) return -1;
770 if (!$fh) return false;
777 if (!str_ends_with($line, "\n")) continue;
779 // check if line matches
780 if (preg_match($pattern, $line, $match)) {
781 if ($backref) {
788 if ($max && $max == $cnt) break;
807 if (!file_exists($file)) return 0;
809 if (str_ends_with($file, '.gz')) {
811 if ($fp === false) return 0;
818 if (!DOKU_HAS_BZIP) return 0;
820 if ($bz === false) return 0;
825 if (($buffer === false) || (bzerrno($bz) !== 0)) {