Fix new layout path location

Was "www/layout/admin|frontend/..." now is
www/frontend/layout and www/admin/layout
This commit is contained in:
Clemens Schwaighofer
2024-03-07 14:53:00 +09:00
parent f59c325b05
commit 9f734dbf30
2 changed files with 6 additions and 6 deletions

View File

@@ -41,9 +41,9 @@ print '<div><h1>' . $PAGE_NAME . '</h1></div>';
$thumb_width = 250; $thumb_width = 250;
$thumb_height = 300; $thumb_height = 300;
// class // class
$image = BASE . LAYOUT . CONTENT_PATH . IMAGES . 'no_picture_square.jpg'; $image = BASE . CONTENT_PATH . LAYOUT . IMAGES . 'no_picture_square.jpg';
// folders // folders
$cache_folder = BASE . LAYOUT . CONTENT_PATH . CACHE . IMAGES; $cache_folder = BASE . CONTENT_PATH . LAYOUT . CACHE . IMAGES;
$web_folder = LAYOUT . CACHE . IMAGES; $web_folder = LAYOUT . CACHE . IMAGES;
// rotate image first // rotate image first
try { try {
@@ -58,7 +58,7 @@ echo "<div>CLASS->CREATETHUMBNAILSIMPLE: "
. basename($image) . ": WIDTH: $thumb_width<br><img src=" . basename($image) . ": WIDTH: $thumb_width<br><img src="
. $_image->createThumbnailSimple($image, $thumb_width, 0, $cache_folder, $web_folder) . "></div>"; . $_image->createThumbnailSimple($image, $thumb_width, 0, $cache_folder, $web_folder) . "></div>";
// static // static
$image = BASE . LAYOUT . CONTENT_PATH . IMAGES . 'no_picture.jpg'; $image = BASE . CONTENT_PATH . LAYOUT . IMAGES . 'no_picture.jpg';
// rotate image first // rotate image first
try { try {
$image_class::correctImageOrientation($image); $image_class::correctImageOrientation($image);
@@ -94,7 +94,7 @@ $images = array(
// return mime type ala mimetype // return mime type ala mimetype
$finfo = new finfo(FILEINFO_MIME_TYPE); $finfo = new finfo(FILEINFO_MIME_TYPE);
foreach ($images as $image) { foreach ($images as $image) {
$image = BASE . LAYOUT . CONTENT_PATH . IMAGES . $image; $image = BASE . CONTENT_PATH . LAYOUT . IMAGES . $image;
list ($height, $width, $img_type) = \CoreLibs\Convert\SetVarType::setArray(getimagesize($image)); list ($height, $width, $img_type) = \CoreLibs\Convert\SetVarType::setArray(getimagesize($image));
echo "<div><b>IMAGE INFO</b>: " . $height . "x" . $width . ", TYPE: " echo "<div><b>IMAGE INFO</b>: " . $height . "x" . $width . ", TYPE: "
. \CoreLibs\Debug\Support::dumpVar($img_type) . " [" . $finfo->file($image) . "]</div>"; . \CoreLibs\Debug\Support::dumpVar($img_type) . " [" . $finfo->file($image) . "]</div>";

View File

@@ -204,11 +204,11 @@ class Image
E_USER_DEPRECATED E_USER_DEPRECATED
); );
// NOTE: we need to depracte this // NOTE: we need to depracte this
$cache_folder = BASE . LAYOUT . CONTENT_PATH . CACHE . IMAGES; $cache_folder = BASE . CONTENT_PATH . LAYOUT . CACHE . IMAGES;
$web_folder = LAYOUT . CACHE . IMAGES; $web_folder = LAYOUT . CACHE . IMAGES;
if (!is_dir($cache_folder)) { if (!is_dir($cache_folder)) {
if (false === mkdir($cache_folder)) { if (false === mkdir($cache_folder)) {
$cache_folder = BASE . LAYOUT . CONTENT_PATH . CACHE; $cache_folder = BASE . CONTENT_PATH . LAYOUT . CACHE;
$web_folder = LAYOUT . CACHE; $web_folder = LAYOUT . CACHE;
} }
} }