Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93
/home/sportsfe.../httpdocs/wp-conte.../plugins/wp-file-.../lib/js/commands
File: reload.js
/**
[0] Fix | Delete
* @class elFinder command "reload"
[1] Fix | Delete
* Sync files and folders
[2] Fix | Delete
*
[3] Fix | Delete
* @author Dmitry (dio) Levashov
[4] Fix | Delete
**/
[5] Fix | Delete
(elFinder.prototype.commands.reload = function() {
[6] Fix | Delete
"use strict";
[7] Fix | Delete
var self = this,
[8] Fix | Delete
search = false;
[9] Fix | Delete
[10] Fix | Delete
this.alwaysEnabled = true;
[11] Fix | Delete
this.updateOnSelect = true;
[12] Fix | Delete
[13] Fix | Delete
this.shortcuts = [{
[14] Fix | Delete
pattern : 'ctrl+shift+r f5'
[15] Fix | Delete
}];
[16] Fix | Delete
[17] Fix | Delete
this.getstate = function() {
[18] Fix | Delete
return 0;
[19] Fix | Delete
};
[20] Fix | Delete
[21] Fix | Delete
this.init = function() {
[22] Fix | Delete
this.fm.bind('search searchend', function() {
[23] Fix | Delete
search = this.type == 'search';
[24] Fix | Delete
});
[25] Fix | Delete
};
[26] Fix | Delete
[27] Fix | Delete
this.fm.bind('contextmenu', function(){
[28] Fix | Delete
var fm = self.fm;
[29] Fix | Delete
if (fm.options.sync >= 1000) {
[30] Fix | Delete
self.extra = {
[31] Fix | Delete
icon: 'accept',
[32] Fix | Delete
node: jQuery('<span></span>')
[33] Fix | Delete
.attr({title: fm.i18n('autoSync')})
[34] Fix | Delete
.on('click touchstart', function(e){
[35] Fix | Delete
if (e.type === 'touchstart' && e.originalEvent.touches.length > 1) {
[36] Fix | Delete
return;
[37] Fix | Delete
}
[38] Fix | Delete
e.stopPropagation();
[39] Fix | Delete
e.preventDefault();
[40] Fix | Delete
jQuery(this).parent()
[41] Fix | Delete
.toggleClass('ui-state-disabled', fm.options.syncStart)
[42] Fix | Delete
.parent().removeClass('ui-state-hover');
[43] Fix | Delete
fm.options.syncStart = !fm.options.syncStart;
[44] Fix | Delete
fm.autoSync(fm.options.syncStart? null : 'stop');
[45] Fix | Delete
}).on('ready', function(){
[46] Fix | Delete
jQuery(this).parent().toggleClass('ui-state-disabled', !fm.options.syncStart).css('pointer-events', 'auto');
[47] Fix | Delete
})
[48] Fix | Delete
};
[49] Fix | Delete
}
[50] Fix | Delete
});
[51] Fix | Delete
[52] Fix | Delete
this.exec = function() {
[53] Fix | Delete
var fm = this.fm;
[54] Fix | Delete
if (!search) {
[55] Fix | Delete
var dfrd = fm.sync(),
[56] Fix | Delete
timeout = setTimeout(function() {
[57] Fix | Delete
fm.notify({type : 'reload', cnt : 1, hideCnt : true});
[58] Fix | Delete
dfrd.always(function() { fm.notify({type : 'reload', cnt : -1}); });
[59] Fix | Delete
}, fm.notifyDelay);
[60] Fix | Delete
[61] Fix | Delete
return dfrd.always(function() {
[62] Fix | Delete
clearTimeout(timeout);
[63] Fix | Delete
fm.trigger('reload');
[64] Fix | Delete
});
[65] Fix | Delete
} else {
[66] Fix | Delete
jQuery('div.elfinder-toolbar > div.'+fm.res('class', 'searchbtn') + ' > span.ui-icon-search').click();
[67] Fix | Delete
}
[68] Fix | Delete
};
[69] Fix | Delete
[70] Fix | Delete
}).prototype = { forceLoad : true }; // this is required command
[71] Fix | Delete
[72] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function