Lines Matching refs:file
359 //file doesnt exist yet, so we take the configured extension
373 * Returns the full path to the file for locking the page while editing.
388 * returns the full path to the meta file specified by ID and extension
393 * @param string $ext file extension
407 * returns the full path to the media's meta file specified by ID and extension
472 * Returns the full filepath to a localized file if local
475 * @param string $id The id of the local file
476 * @param string $ext The file extension (usually txt)
477 * @return string full filepath to localized file
484 $file = DOKU_CONF . 'lang/' . $conf['lang'] . '/' . $id . '.' . $ext;
485 if (!file_exists($file)) {
486 $file = DOKU_INC . 'inc/lang/' . $conf['lang'] . '/' . $id . '.' . $ext;
487 if (!file_exists($file)) {
489 $file = DOKU_INC . 'inc/lang/en/' . $id . '.' . $ext;
492 return $file;
611 $file = $conf['cachedir'] . '/' . $md5[0] . '/' . $md5 . $ext;
612 io_makeFileDir($file);
613 return $file;
698 * @param string $file file name
702 function utf8_encodeFN($file, $safe = true)
705 if ($conf['fnencode'] == 'utf-8') return $file;
707 if ($safe && preg_match('#^[a-zA-Z0-9/_\-\.%]+$#', $file)) {
708 return $file;
712 return SafeFN::encode($file);
715 $file = urlencode($file);
716 $file = str_replace('%2F', '/', $file);
717 return $file;
728 * @param string $file file name
731 function utf8_decodeFN($file)
734 if ($conf['fnencode'] == 'utf-8') return $file;
737 return SafeFN::decode($file);
740 return urldecode($file);