@@ -9442,11 +9442,11 @@ function api_site_use_cookie_warning_cookie_exist()
9442
9442
* Given a number of seconds, format the time to show hours, minutes and seconds.
9443
9443
*
9444
9444
* @param int $time The time in seconds
9445
- * @param string $originFormat Optional.
9445
+ * @param string $originFormat Optional.
9446
9446
* PHP (used for scorm)
9447
9447
* JS (used in most cases and understood by excel)
9448
9448
* LANG (used to present unit in the user language)
9449
- *
9449
+ *
9450
9450
* @return string (00h00'00")
9451
9451
*/
9452
9452
function api_format_time ($ time , $ originFormat = 'php ' )
@@ -9675,6 +9675,22 @@ function api_mail_html(
9675
9675
}
9676
9676
if (isset ($ additionalParameters ['logo ' ])) {
9677
9677
$ mailView ->assign ('logo ' , $ additionalParameters ['logo ' ]);
9678
+ } elseif (api_get_configuration_value ('email_logo ' ) == true ) {
9679
+ $ logoSubPath = 'themes/ ' .api_get_visual_theme ().'/images/email-logo.png ' ;
9680
+ $ logoSysPath = api_get_path (SYS_PATH ).'web/css/ ' .$ logoSubPath ;
9681
+ if (file_exists ($ logoSysPath )) {
9682
+ $ logoWebPath = api_get_path (WEB_CSS_PATH ).$ logoSubPath ;
9683
+ $ imgTag = \Display::img (
9684
+ $ logoWebPath ,
9685
+ api_get_setting ('siteName ' ),
9686
+ [
9687
+ 'id ' => 'header-logo ' ,
9688
+ 'class ' => 'img-responsive '
9689
+ ]
9690
+ );
9691
+ $ logoTag = \Display::url ($ imgTag , api_get_path (WEB_PATH ));
9692
+ $ mailView ->assign ('logo ' , $ logoTag );
9693
+ }
9678
9694
}
9679
9695
$ mailView ->assign ('mail_header_style ' , api_get_configuration_value ('mail_header_style ' ));
9680
9696
$ mailView ->assign ('mail_content_style ' , api_get_configuration_value ('mail_content_style ' ));
0 commit comments