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/custom-t.../admin/assets/js
File: about.js
var extensions_data = {
[0] Fix | Delete
genericText: ctf_about.genericText,
[1] Fix | Delete
links: ctf_about.links,
[2] Fix | Delete
extentions_bundle: ctf_about.extentions_bundle,
[3] Fix | Delete
supportPageUrl: ctf_about.supportPageUrl,
[4] Fix | Delete
plugins: ctf_about.pluginsInfo,
[5] Fix | Delete
stickyWidget: false,
[6] Fix | Delete
socialWallActivated: ctf_about.socialWallActivated,
[7] Fix | Delete
socialWallLinks: ctf_about.socialWallLinks,
[8] Fix | Delete
recommendedPlugins: ctf_about.recommendedPlugins,
[9] Fix | Delete
social_wall: ctf_about.social_wall,
[10] Fix | Delete
aboutBox: ctf_about.aboutBox,
[11] Fix | Delete
ajax_handler: ctf_about.ajax_handler,
[12] Fix | Delete
nonce: ctf_about.nonce,
[13] Fix | Delete
buttons: ctf_about.buttons,
[14] Fix | Delete
icons: ctf_about.icons,
[15] Fix | Delete
btnClicked: null,
[16] Fix | Delete
btnStatus: null,
[17] Fix | Delete
btnName: null,
[18] Fix | Delete
}
[19] Fix | Delete
[20] Fix | Delete
var ctfAbout = new Vue({
[21] Fix | Delete
el: "#ctf-about",
[22] Fix | Delete
http: {
[23] Fix | Delete
emulateJSON: true,
[24] Fix | Delete
emulateHTTP: true
[25] Fix | Delete
},
[26] Fix | Delete
data: extensions_data,
[27] Fix | Delete
methods: {
[28] Fix | Delete
activatePlugin: function( plugin, name, index, type ) {
[29] Fix | Delete
this.btnClicked = index + 1;
[30] Fix | Delete
this.btnStatus = 'loading';
[31] Fix | Delete
this.btnName = name;
[32] Fix | Delete
[33] Fix | Delete
let data = new FormData();
[34] Fix | Delete
data.append( 'action', 'ctf_activate_addon' );
[35] Fix | Delete
data.append( 'nonce', this.nonce );
[36] Fix | Delete
data.append( 'plugin', plugin );
[37] Fix | Delete
data.append( 'type', 'plugin' );
[38] Fix | Delete
if ( this.extentions_bundle && type == 'extension' ) {
[39] Fix | Delete
data.append( 'extensions_bundle', this.extentions_bundle );
[40] Fix | Delete
}
[41] Fix | Delete
fetch(this.ajax_handler, {
[42] Fix | Delete
method: "POST",
[43] Fix | Delete
credentials: 'same-origin',
[44] Fix | Delete
body: data
[45] Fix | Delete
})
[46] Fix | Delete
.then(response => response.json())
[47] Fix | Delete
.then(data => {
[48] Fix | Delete
if( data.success == true ) {
[49] Fix | Delete
if ( name === 'social_wall' ) {
[50] Fix | Delete
this.social_wall.activated = true;
[51] Fix | Delete
} else if ( type === 'recommended_plugin' ) {
[52] Fix | Delete
this.recommendedPlugins[name].activated = true;
[53] Fix | Delete
} else {
[54] Fix | Delete
this.plugins[name].activated = true;
[55] Fix | Delete
}
[56] Fix | Delete
this.btnClicked = null;
[57] Fix | Delete
this.btnStatus = null;
[58] Fix | Delete
this.btnName = null;
[59] Fix | Delete
}
[60] Fix | Delete
});
[61] Fix | Delete
},
[62] Fix | Delete
deactivatePlugin: function( plugin, name, index, type ) {
[63] Fix | Delete
this.btnClicked = index + 1;
[64] Fix | Delete
this.btnStatus = 'loading';
[65] Fix | Delete
this.btnName = name;
[66] Fix | Delete
[67] Fix | Delete
let data = new FormData();
[68] Fix | Delete
data.append( 'action', 'ctf_deactivate_addon' );
[69] Fix | Delete
data.append( 'nonce', this.nonce );
[70] Fix | Delete
data.append( 'plugin', plugin );
[71] Fix | Delete
data.append( 'type', 'plugin' );
[72] Fix | Delete
if ( this.extentions_bundle && type == 'extension' ) {
[73] Fix | Delete
data.append( 'extensions_bundle', this.extentions_bundle );
[74] Fix | Delete
}
[75] Fix | Delete
fetch(this.ajax_handler, {
[76] Fix | Delete
method: "POST",
[77] Fix | Delete
credentials: 'same-origin',
[78] Fix | Delete
body: data
[79] Fix | Delete
})
[80] Fix | Delete
.then(response => response.json())
[81] Fix | Delete
.then(data => {
[82] Fix | Delete
if( data.success == true ) {
[83] Fix | Delete
if ( name === 'social_wall' ) {
[84] Fix | Delete
this.social_wall.activated = false;
[85] Fix | Delete
} else if ( type === 'recommended_plugin' ) {
[86] Fix | Delete
this.recommendedPlugins[name].activated = false;
[87] Fix | Delete
} else {
[88] Fix | Delete
this.plugins[name].activated = false;
[89] Fix | Delete
}
[90] Fix | Delete
this.btnClicked = null;
[91] Fix | Delete
this.btnName = null;
[92] Fix | Delete
this.btnStatus = null;
[93] Fix | Delete
}
[94] Fix | Delete
return;
[95] Fix | Delete
});
[96] Fix | Delete
},
[97] Fix | Delete
installPlugin: function( plugin, name, index, type ) {
[98] Fix | Delete
this.btnClicked = index + 1;
[99] Fix | Delete
this.btnStatus = 'loading';
[100] Fix | Delete
this.btnName = name;
[101] Fix | Delete
[102] Fix | Delete
let data = new FormData();
[103] Fix | Delete
data.append( 'action', 'ctf_install_addon' );
[104] Fix | Delete
data.append( 'nonce', this.nonce );
[105] Fix | Delete
data.append( 'plugin', plugin );
[106] Fix | Delete
data.append( 'type', 'plugin' );
[107] Fix | Delete
fetch(this.ajax_handler, {
[108] Fix | Delete
method: "POST",
[109] Fix | Delete
credentials: 'same-origin',
[110] Fix | Delete
body: data
[111] Fix | Delete
})
[112] Fix | Delete
.then(response => response.json())
[113] Fix | Delete
.then(data => {
[114] Fix | Delete
if( data.success == true ) {
[115] Fix | Delete
if ( type === 'recommended_plugin' ) {
[116] Fix | Delete
this.recommendedPlugins[name].installed = true;
[117] Fix | Delete
this.recommendedPlugins[name].activated = true;
[118] Fix | Delete
} else {
[119] Fix | Delete
this.plugins[name].installed = true;
[120] Fix | Delete
this.plugins[name].activated = true;
[121] Fix | Delete
}
[122] Fix | Delete
this.btnClicked = null;
[123] Fix | Delete
this.btnName = null;
[124] Fix | Delete
this.btnStatus = null;
[125] Fix | Delete
}
[126] Fix | Delete
return;
[127] Fix | Delete
});
[128] Fix | Delete
},
[129] Fix | Delete
buttonIcon: function() {
[130] Fix | Delete
if ( this.btnStatus == 'loading' ) {
[131] Fix | Delete
return this.icons.loaderSVG
[132] Fix | Delete
}
[133] Fix | Delete
},
[134] Fix | Delete
[135] Fix | Delete
/**
[136] Fix | Delete
* Toggle Sticky Widget view
[137] Fix | Delete
*
[138] Fix | Delete
* @since 2.0
[139] Fix | Delete
*/
[140] Fix | Delete
toggleStickyWidget: function() {
[141] Fix | Delete
this.stickyWidget = !this.stickyWidget;
[142] Fix | Delete
},
[143] Fix | Delete
}
[144] Fix | Delete
})
[145] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function