1<?php 2/** 3 * Elgg cron library. 4 */ 5 6/** 7 * Cron initialization 8 * 9 * @return void 10 * @internal 11 */ 12function _elgg_cron_init() { 13 elgg_register_menu_item('page', [ 14 'name' => 'cron', 15 'text' => elgg_echo('admin:cron'), 16 'href' => 'admin/cron', 17 'section' => 'information', 18 'context' => 'admin', 19 ]); 20} 21 22/** 23 * @see \Elgg\Application::loadCore Do not do work here. Just register for events. 24 */ 25return function (\Elgg\EventsService $events, \Elgg\HooksRegistrationService $hooks) { 26 $events->registerHandler('init', 'system', '_elgg_cron_init'); 27}; 28