Skip to content

Commit 0a6aa75

Browse files
committed
Internal: Remove text/javascript type attribute for JavaScript files - See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script
1 parent 320f16a commit 0a6aa75

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

main/inc/lib/template.lib.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -799,7 +799,7 @@ public function set_js_files()
799799
}
800800

801801
foreach ($bowerJsFiles as $file) {
802-
$js_file_to_string .= '<script type="text/javascript" src="'.api_get_cdn_path(api_get_path(WEB_PUBLIC_PATH).'assets/'.$file).'"></script>'."\n";
802+
$js_file_to_string .= '<script src="'.api_get_cdn_path(api_get_path(WEB_PUBLIC_PATH).'assets/'.$file).'"></script>'."\n";
803803
}
804804

805805
foreach ($js_files as $file) {
@@ -869,8 +869,8 @@ public function set_js_files_post()
869869
//Do not include the global chat in LP
870870
if ($this->show_learnpath == false && $this->show_footer == true && $this->hide_global_chat == false) {
871871
$js_files[] = 'chat/js/chat.js';
872-
$bower .= '<script type="text/javascript" src="'.api_get_path(WEB_PUBLIC_PATH).'assets/linkifyjs/linkify.js"></script>';
873-
$bower .= '<script type="text/javascript" src="'.api_get_path(WEB_PUBLIC_PATH).'assets/linkifyjs/linkify-jquery.js"></script>';
872+
$bower .= '<script src="'.api_get_path(WEB_PUBLIC_PATH).'assets/linkifyjs/linkify.js"></script>';
873+
$bower .= '<script src="'.api_get_path(WEB_PUBLIC_PATH).'assets/linkifyjs/linkify-jquery.js"></script>';
874874
}
875875
}
876876
$js_file_to_string = '';

0 commit comments

Comments
 (0)