autosaveFrequency: {
value: 60,
writeOnce: true
+ },
+
+ /**
+ * The relative path to the ajax script.
+ *
+ * @attribute autosaveAjaxScript
+ * @type String
+ * @default '/lib/editor/atto/autosave-ajax.php'
+ * @readOnly
+ */
+ autosaveAjaxScript: {
+ value: '/lib/editor/atto/autosave-ajax.php',
+ readOnly: true
}
};
// First see if there are any saved drafts.
// Make an ajax request.
- url = M.cfg.wwwroot + '/lib/editor/atto/autosave-ajax.php';
+ url = M.cfg.wwwroot + this.get('autosaveAjaxScript');
params = {
sesskey: M.cfg.sesskey,
contextid: this.get('contextid'),
*/
resetAutosave: function() {
// Make an ajax request to reset the autosaved text.
- url = M.cfg.wwwroot + '/lib/editor/atto/autosave-ajax.php';
+ url = M.cfg.wwwroot + this.get('autosaveAjaxScript');
params = {
sesskey: M.cfg.sesskey,
contextid: this.get('contextid'),
Y.log('Autosave text', 'debug', LOGNAME_AUTOSAVE);
// Make an ajax request.
- url = M.cfg.wwwroot + '/lib/editor/atto/autosave-ajax.php';
+ url = M.cfg.wwwroot + this.get('autosaveAjaxScript');
params = {
sesskey: M.cfg.sesskey,
contextid: this.get('contextid'),