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
/**
* A collection of utility classes for use with course sections.
*
* @module moodle-course-util
* @submodule moodle-course-util-section
*/
Y.namespace('Moodle.core_course.util.section');
/**
* A collection of utility classes for use with course sections.
*
* @class Moodle.core_course.util.section
* @static
*/
Y.Moodle.core_course.util.section = {
CONSTANTS: {
SECTIONIDPREFIX: 'section-'
},
/**
* Determines the section ID for the provided section.
*
* @method getId
* @param section {Node} The section to find an ID for.
* @return {Number|false} The ID of the section in question or false if no ID was found.
*/
getId: function(section) {
// We perform a simple substitution operation to get the ID.
var id = section.get('id').replace(
this.CONSTANTS.SECTIONIDPREFIX, '');
// Attempt to validate the ID.
id = parseInt(id, 10);
if (typeof id === 'number' && isFinite(id)) {
return id;
}
return false;
}
};