19 declare(strict_types=1);
36 $f = $DIC->ui()->factory();
40 $image =
$f->image()->standard(
41 "assets/ui-examples/images/Image/HeaderIconLarge.svg",
44 ->withAdditionalOnLoadCode(
function (
$id) {
45 return "$('#$id').click(function(e) { e.preventDefault(); alert('Image Onload Code')});";
with_additional_on_load_code()
description: > Example showing how JS-Code can be attached to images.
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins