Misc/Cleanup

* moving commonly used strings to defines
 * moving commonly reused/similar page generation functions to the parent
 * generally using consistent return types, more type hints and less strings
 * prevent browser context menu when right clicking on UI elements with their own context menus
 * fixed menu path for icons
This commit is contained in:
Sarjuuk
2020-05-23 13:01:10 +02:00
parent b044488308
commit 6cabfd3864
38 changed files with 418 additions and 618 deletions

View File

@@ -217,7 +217,7 @@ class AjaxProfile extends AjaxHandler
return;
}
$this->contentType = 'image/'.$matches[2];
$this->contentType = $matches[2] == 'png' ? MIME_TYPE_PNG : MIME_TYPE_JPEG;
$id = $matches[1];
$dest = imageCreateTruecolor($sizes[$s], $sizes[$s]);