本文整理匯總了PHP中Handler::uploaded_images方法的典型用法代碼示例。如果您正苦於以下問題:PHP Handler::uploaded_images方法的具體用法?PHP Handler::uploaded_images怎麽用?PHP Handler::uploaded_images使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Handler
的用法示例。
在下文中一共展示了Handler::uploaded_images方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: proccess_request
//.........這裏部分代碼省略.........
self::$is_viewer = true;
break;
case 'maintenance':
$this->template = 'maintenance';
self::$doctitle = chevereto_config('doctitle');
break;
default:
// Pages request
require_once $this->path_theme . 'pages/pages_config.php';
// We load the special pages config
if (in_array($this->base_request . '.php', $this->pages) and $this->request_array[1] == '' and $pages_config[$this->base_request]['live']) {
$this->template = 'pages/' . $this->base_request;
self::$doctitle = $pages_config[$this->base_request]['title'];
} else {
$this->template = 'shorturl';
$id_public = $this->base_request;
self::$is_viewer = true;
}
break;
}
// Ask for the login on index and pages
if ($this->template == 'index' || $this->template == 'pages/' . $this->base_request) {
if (conditional_config('private_mode')) {
if (!is_logged_user()) {
$doctitle = get_lang_txt('txt_enter_password') . ' - ' . chevereto_config('doctitle');
include __CHV_PATH_SYSTEM__ . 'login.php';
die;
}
}
}
if ($this->template == 'uploaded') {
self::$doctitle = get_lang_txt('doctitle_upload_complete');
self::$image_info = $_SESSION['ImagesUp'][0];
self::$uploaded_images = $_SESSION['ImagesUp'];
$_SESSION['ImagesUp'] = NULL;
unset($_SESSION['ImagesUp']);
}
if (preg_match('/view|shorturl|delete/', $this->template) || $this->legacy_redirect) {
// Test connection
if ($this->dB->dead) {
self::$doctitle = 'dB connection error';
$this->template = 404;
} else {
// get image info
$imageID = $this->legacy_redirect ? $id_public : decodeID($id_public);
self::$image_info = $this->dB->image_info($imageID);
self::$id_public = $id_public;
if (!is_array(self::$image_info)) {
// Record?
if ($this->template == 'delete-confirm') {
json_output(array('status_code' => 403, 'status_txt' => 'target image doesn\'t exists'));
} else {
$this->template = 404;
}
} else {
if ($this->legacy_redirect) {
$this->redirect(__CHV_BASE_URL__ . __CHV_VIRTUALFOLDER_IMAGE__ . '/' . encodeID(self::$image_info['image_id']), 301);
}
$target = get_image_target(self::$image_info);
self::$image_target = $target['image_path'];
self::$image_thumb_target = $target['image_thumb_path'];
self::$image_url = absolute_to_url($target['image_path']);
self::$image_thumb_url = absolute_to_url($target['image_thumb_path']);
self::$image_filename = self::$image_info['image_filename'];
self::$image_viewer = __CHV_BASE_URL__ . __CHV_VIRTUALFOLDER_IMAGE__ . '/' . $id_public;
self::$delete_image_url = __CHV_BASE_URL__ . 'delete/image/' . self::$id_public . '/' . self::$image_info['image_delete_hash'];