Update Embedfiles.php

eliminates a database call
This commit is contained in:
Ray 2023-03-11 20:52:46 -05:00
parent 58609c0670
commit b56d4753a7

View file

@ -170,22 +170,6 @@ class Embedfiles extends Controller
$ext = EMPTY_STR;
}
// $alt = $r[0]['title'];
//$alt = $_POST["filename"];
/*
if (!$alt) {
$a = q(
"select filename from attach where hash = '%s' and uid = %d limit 1",
dbesc($resource),
intval($channel['channel_id'])
);
if ($a) {
$alt = $a[0]['filename'];
} else {
$alt = t('Image/photo');
}
}
*/
$alt = ' alt="' . $_POST["filename"] . '"';
$output = '[zrl=' . z_root() . '/photos/' . $channel['channel_address'] . '/image/' . $resource . ']'