summaryrefslogtreecommitdiff
path: root/src/web/lib/image.php
diff options
context:
space:
mode:
authorFreya Murphy <freya@freyacat.org>2026-02-23 22:57:27 -0500
committerFreya Murphy <freya@freyacat.org>2026-02-23 22:57:27 -0500
commitf373ead95fb5beb962c376b5b7b46dfde8ac4e57 (patch)
treec99df23521ff2a5e5e2e4627c525a5e99dc2e3ae /src/web/lib/image.php
parentadd 96x96 logo (diff)
downloadwebsite-f373ead95fb5beb962c376b5b7b46dfde8ac4e57.tar.gz
website-f373ead95fb5beb962c376b5b7b46dfde8ac4e57.tar.bz2
website-f373ead95fb5beb962c376b5b7b46dfde8ac4e57.zip
update website to work with crimson framework
Diffstat (limited to '')
-rw-r--r--src/web/lib/image.php (renamed from src/web/helpers/image.php)6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/web/helpers/image.php b/src/web/lib/image.php
index d4683fe..7b6ec0e 100644
--- a/src/web/helpers/image.php
+++ b/src/web/lib/image.php
@@ -1,5 +1,7 @@
<?php /* Copyright (c) 2024 Freya Murphy */
+
+
function __get_mime($type)
{
switch ($type) {
@@ -30,7 +32,7 @@ function __make_source(
} else {
$media = '';
}
- $path = Core::get_url('public/' . $name . '.' . $format, TRUE);
+ $path = Base::get_url('public/' . $name . '.' . $format, TRUE);
$mime = __get_mime($format);
return sprintf('<source type="%s" srcset="%s" %s>',
$mime, $path, $media);
@@ -68,7 +70,7 @@ function image(
}
$format = end($formats);
- $path = Core::get_url('public/' . $name . '.' . $format, TRUE);
+ $path = Base::get_url('public/' . $name . '.' . $format, TRUE);
$out .= "<img src=\"$path\"";
if ($alt) {
$alt = lang($alt);