Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
in /home/monara/public_html/test.athavaneng.com/themes.php on line 99
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 226
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 227
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 228
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 229
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 230
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 231
.
/**
* Contains class core_tag_collections_table
*
* @package core_tag
* @copyright 2015 Marina Glancy
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
defined('MOODLE_INTERNAL') || die();
/**
* Table with the list of tag collections for "Manage tags" page.
*
* @package core_tag
* @copyright 2015 Marina Glancy
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
class core_tag_collections_table extends html_table {
/**
* Constructor
* @param string|moodle_url $pageurl
*/
public function __construct($pageurl) {
global $OUTPUT;
parent::__construct();
$this->attributes['class'] = 'generaltable tag-collections-table';
$this->head = array(
get_string('name'),
get_string('component', 'tag'),
get_string('tagareas', 'tag'),
get_string('searchable', 'tag') . $OUTPUT->help_icon('searchable', 'tag'),
''
);
$this->data = array();
$tagcolls = core_tag_collection::get_collections();
$idx = 0;
foreach ($tagcolls as $tagcoll) {
$actions = '';
$name = core_tag_collection::display_name($tagcoll);
$url = new moodle_url($pageurl, array('sesskey' => sesskey(), 'tc' => $tagcoll->id));
if (!$tagcoll->isdefault) {
// Move up.
if ($idx > 1) {
$url->param('action', 'collmoveup');
$actions .= $OUTPUT->action_icon($url, new pix_icon('t/up', get_string('moveup')), null,
array('class' => 'action-icon action_moveup'));
}
// Move down.
if ($idx < count($tagcolls) - 1) {
$url->param('action', 'collmovedown');
$actions .= $OUTPUT->action_icon($url, new pix_icon('t/down', get_string('movedown')), null,
array('class' => 'action-icon action_movedown'));
}
}
if (!$tagcoll->isdefault && empty($tagcoll->component)) {
// Delete.
$url->param('action', 'colldelete');
$actions .= $OUTPUT->action_icon('#', new pix_icon('t/delete', get_string('delete')), null,
array('data-url' => $url->out(false), 'data-collname' => $name,
'class' => 'action-icon action_delete'));
}
$component = '';
if ($tagcoll->component) {
$component = ($tagcoll->component === 'core' || preg_match('/^core_/', $tagcoll->component)) ?
get_string('coresystem') : get_string('pluginname', $tagcoll->component);
}
$allareas = core_tag_collection::get_areas_names(null, false);
$validareas = core_tag_collection::get_areas_names($tagcoll->id);
$areaslist = array_map(function($key) use ($allareas, $validareas) {
return "{$allareas[$key]}";
}, array_keys($allareas));
$displayname = new \core_tag\output\tagcollname($tagcoll);
$searchable = new \core_tag\output\tagcollsearchable($tagcoll);
$this->data[] = array(
$displayname->render($OUTPUT),
$component,
"id}\">" . join('', $areaslist) . '
',
$searchable->render($OUTPUT),
$actions);
$idx++;
}
}
}