Site logo implementation
This commit is contained in:
parent
7e6a5cd28c
commit
74b68e507a
@ -475,7 +475,7 @@
|
||||
<label class="custom-file-label" for="jssiteLogoInputFile"><?php $L->p('Choose images to upload'); ?></label>
|
||||
</div>
|
||||
<div>
|
||||
<img id="jssiteLogoPreview" class="img-fluid img-thumbnail" alt="Site logo preview" src="<?php echo (Sanitize::pathFile(PATH_UPLOADS.$site->logo(false))?DOMAIN_UPLOADS.$site->logo(false).'?version='.time():HTML_PATH_ADMIN_THEME_IMG.'default.svg') ?>" />
|
||||
<img id="jssiteLogoPreview" class="img-fluid img-thumbnail" alt="Site logo preview" src="<?php echo ($site->logo()?DOMAIN_UPLOADS.$site->logo(false).'?version='.time():HTML_PATH_ADMIN_THEME_IMG.'default.svg') ?>" />
|
||||
</div>
|
||||
<script>
|
||||
$("#jssiteLogoInputFile").on("change", function() {
|
||||
|
@ -274,7 +274,7 @@ class Site extends dbJSON {
|
||||
public function logo($absolute=true)
|
||||
{
|
||||
$logo = $this->getField('logo');
|
||||
if ($absolute) {
|
||||
if ($absolute && $logo) {
|
||||
return DOMAIN_UPLOADS.$logo;
|
||||
}
|
||||
return $logo;
|
||||
|
Loading…
Reference in New Issue
Block a user