}
// setup variables for non-js interface
self::$nonjs = optional_param('nonjscomment', '', PARAM_ALPHANUM);
- self::$comment_itemid = optional_param('comment_itemid', '', PARAM_INT);
+ self::$comment_itemid = optional_param('comment_itemid', '', PARAM_INT);
+ self::$comment_component = optional_param('comment_component', '', PARAM_COMPONENT);
self::$comment_context = optional_param('comment_context', '', PARAM_INT);
- self::$comment_page = optional_param('comment_page', '', PARAM_INT);
- self::$comment_area = optional_param('comment_area', '', PARAM_AREA);
+ self::$comment_page = optional_param('comment_page', '', PARAM_INT);
+ self::$comment_area = optional_param('comment_area', '', PARAM_AREA);
- $page->requires->string_for_js('addcomment', 'moodle');
- $page->requires->string_for_js('deletecomment', 'moodle');
- $page->requires->string_for_js('comments', 'moodle');
- $page->requires->string_for_js('commentsrequirelogin', 'moodle');
+ $page->requires->strings_for_js(array(
+ 'addcomment',
+ 'comments',
+ 'commentscount',
+ 'commentsrequirelogin',
+ 'deletecomment',
+ ),
+ 'moodle'
+ );
}
/**
<?xml version="1.0" encoding="UTF-8" ?>
- <XMLDB PATH="lib/db" VERSION="20141117" COMMENT="XMLDB file for core Moodle tables"
-<XMLDB PATH="lib/db" VERSION="20141113" COMMENT="XMLDB file for core Moodle tables"
++<XMLDB PATH="lib/db" VERSION="20141201" COMMENT="XMLDB file for core Moodle tables"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../lib/xmldb/xmldb.xsd"
>
</KEYS>
</TABLE>
</TABLES>
--</XMLDB>
++</XMLDB>
// Moodle v2.8.0 release upgrade line.
// Put any upgrade step following this.
- if ($oldversion < 2014112800.00) {
+ if ($oldversion < 2014120100.00) {
+
+ // Define field sslverification to be added to mnet_host.
+ $table = new xmldb_table('mnet_host');
+ $field = new xmldb_field('sslverification', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'applicationid');
+
+ // Conditionally launch add field sslverification.
+ if (!$dbman->field_exists($table, $field)) {
+ $dbman->add_field($table, $field);
+ }
+
+ // Main savepoint reached.
+ upgrade_main_savepoint(true, 2014120100.00);
+ }
+
++ if ($oldversion < 2014120101.00) {
- upgrade_main_savepoint(true, 2014112800.00);
+ // Define field component to be added to comments.
+ $table = new xmldb_table('comments');
+ $field = new xmldb_field('component', XMLDB_TYPE_CHAR, '255', null, null, null, null, 'contextid');
+
+ // Conditionally launch add field component.
+ if (!$dbman->field_exists($table, $field)) {
+ $dbman->add_field($table, $field);
+ }
+
+ // Main savepoint reached.
-
++ upgrade_main_savepoint(true, 2014120101.00);
+ }
return true;
}
defined('MOODLE_INTERNAL') || die();
- $version = 2014120100.00; // YYYYMMDD = weekly release date of this DEV branch.
-$version = 2014112800.00; // YYYYMMDD = weekly release date of this DEV branch.
++$version = 2014120101.00; // YYYYMMDD = weekly release date of this DEV branch.
// RR = release increments - 00 in DEV branches.
// .XX = incremental changes.