ILIAS  release_10 Revision v10.1-43-ga1241a92c2f
base.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
6 
25 function base()
26 {
27  global $DIC;
28  $f = $DIC->ui()->factory();
29  $renderer = $DIC->ui()->renderer();
30 
31  return $renderer->render($f->button()->month("02-2017")->withOnLoadCode(function ($id) {
32  return "$(\"#$id\").on('il.ui.button.month.changed', function(el, id, month) { alert(\"Clicked: \" + id + ' with ' + month);});";
33  }));
34 }
$renderer
global $DIC
Definition: shib_login.php:25
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:24
base()
description: > Example for rendering a dropdown button showing the default month/year while not open...
Definition: base.php:25