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/twitter-.../admin
File: ajax-backlink.php
<?php
[0] Fix | Delete
if( !defined('ABSPATH') ){ exit();}
[1] Fix | Delete
add_action('wp_ajax_xyz_twap_ajax_backlink', 'xyz_twap_ajax_backlink_call');
[2] Fix | Delete
[3] Fix | Delete
function xyz_twap_ajax_backlink_call() {
[4] Fix | Delete
[5] Fix | Delete
[6] Fix | Delete
global $wpdb;
[7] Fix | Delete
[8] Fix | Delete
if($_POST){
[9] Fix | Delete
if (! isset( $_POST['_wpnonce'] )|| ! wp_verify_nonce( $_POST['_wpnonce'],'backlink' ))
[10] Fix | Delete
{
[11] Fix | Delete
echo 1;die;
[12] Fix | Delete
}
[13] Fix | Delete
if(current_user_can('administrator')){
[14] Fix | Delete
global $wpdb;
[15] Fix | Delete
if(isset($_POST)){
[16] Fix | Delete
if(intval($_POST['enable'])==1){
[17] Fix | Delete
update_option('xyz_credit_link','twap');
[18] Fix | Delete
echo "twap";
[19] Fix | Delete
}
[20] Fix | Delete
if(intval($_POST['enable'])==-1){
[21] Fix | Delete
update_option('xyz_twap_credit_dismiss', "dis");
[22] Fix | Delete
echo -1;
[23] Fix | Delete
}
[24] Fix | Delete
}
[25] Fix | Delete
}
[26] Fix | Delete
}
[27] Fix | Delete
die();
[28] Fix | Delete
}
[29] Fix | Delete
[30] Fix | Delete
add_action('wp_ajax_xyz_twap_xyzscripts_accinfo_auto_update', 'xyz_twap_xyzscripts_accinfo_auto_update_fn');
[31] Fix | Delete
function xyz_twap_xyzscripts_accinfo_auto_update_fn() {
[32] Fix | Delete
global $wpdb;
[33] Fix | Delete
if(current_user_can('administrator')){
[34] Fix | Delete
if($_POST){
[35] Fix | Delete
if (! isset( $_POST['_wpnonce'] )|| ! wp_verify_nonce( $_POST['_wpnonce'],'xyz_twap_xyzscripts_accinfo_nonce' ))
[36] Fix | Delete
{
[37] Fix | Delete
echo 1;die;
[38] Fix | Delete
}
[39] Fix | Delete
global $wpdb;
[40] Fix | Delete
if(isset($_POST)){
[41] Fix | Delete
$xyzscripts_hash_val=stripslashes($_POST['xyz_user_hash']);
[42] Fix | Delete
$xyzscripts_user_id=$_POST['xyz_userid'];
[43] Fix | Delete
update_option('xyz_twap_xyzscripts_user_id', $xyzscripts_user_id);
[44] Fix | Delete
update_option('xyz_twap_xyzscripts_hash_val', $xyzscripts_hash_val);
[45] Fix | Delete
}
[46] Fix | Delete
}
[47] Fix | Delete
}
[48] Fix | Delete
die();
[49] Fix | Delete
}
[50] Fix | Delete
////////////////////////////////////twitter ////////////////////////////////////////////////
[51] Fix | Delete
add_action('wp_ajax_xyz_twap_tw_account_details_auto_update', 'xyz_twap_tw_account_details_auto_update_fn');
[52] Fix | Delete
function xyz_twap_tw_account_details_auto_update_fn() {
[53] Fix | Delete
global $wpdb;
[54] Fix | Delete
if(current_user_can('administrator')){
[55] Fix | Delete
if($_POST){
[56] Fix | Delete
if (! isset( $_POST['_wpnonce'] )|| ! wp_verify_nonce( $_POST['_wpnonce'],'xyz_twap_tw_account_details_nonce' ))
[57] Fix | Delete
{
[58] Fix | Delete
echo -1;die;
[59] Fix | Delete
}
[60] Fix | Delete
global $wpdb;
[61] Fix | Delete
if(isset($_POST)){
[62] Fix | Delete
$twap_sec_key=$_POST['twap_secretkey'];
[63] Fix | Delete
$xyzscripts_user_id=$_POST['xyz_twap_xyzscripts_user_id'];
[64] Fix | Delete
$xyzscripts_hash_val=$_POST['xyz_twap_xyzscripts_hash_val'];
[65] Fix | Delete
$xyz_twap_smapsoln_userid=$_POST['smapsoln_userid'];
[66] Fix | Delete
// $xyz_tw_user_id=$_POST['xyz_tw_user_id'];
[67] Fix | Delete
$xyz_tw_username=$_POST['xyz_tw_username'];
[68] Fix | Delete
update_option('xyz_twap_xyzscripts_user_id', $xyzscripts_user_id);
[69] Fix | Delete
update_option('xyz_twap_xyzscripts_hash_val', $xyzscripts_hash_val);
[70] Fix | Delete
update_option('xyz_twap_smapsoln_secret_key', $twap_sec_key);
[71] Fix | Delete
update_option('xyz_twap_smapsoln_userid', $xyz_twap_smapsoln_userid);
[72] Fix | Delete
update_option('xyz_twap_tw_id', $xyz_tw_username);
[73] Fix | Delete
}
[74] Fix | Delete
}
[75] Fix | Delete
}
[76] Fix | Delete
die();
[77] Fix | Delete
}
[78] Fix | Delete
/////////////////////////////////////////////////////////////////////////////////////////////////
[79] Fix | Delete
add_action('wp_ajax_xyz_twap_del_twuser_entries', 'xyz_twap_del_twuser_entries_fn');
[80] Fix | Delete
function xyz_twap_del_twuser_entries_fn() {
[81] Fix | Delete
global $wpdb;
[82] Fix | Delete
if(current_user_can('administrator')){
[83] Fix | Delete
if($_POST){
[84] Fix | Delete
if (! isset( $_POST['_wpnonce'] )|| ! wp_verify_nonce( $_POST['_wpnonce'],'xyz_twap_del_twuser_entries_nonce' ))
[85] Fix | Delete
{
[86] Fix | Delete
echo 1;die;
[87] Fix | Delete
}
[88] Fix | Delete
$inactive_tw_userid=$_POST['inactive_tw_userid'];
[89] Fix | Delete
$xyz_twap_xyzscripts_user_id = $_POST['xyzscripts_id'];
[90] Fix | Delete
$xyz_twap_xyzscripts_hash_val= $_POST['xyzscripts_user_hash'];
[91] Fix | Delete
$delete_entry_details=array('tw_userid'=>$inactive_tw_userid,
[92] Fix | Delete
'xyzscripts_user_id' =>$xyz_twap_xyzscripts_user_id);
[93] Fix | Delete
$url=XYZ_TWAP_SMAPSOLUTION_AUTH_URL.'authorize-twitter/delete-tw-auth.php';
[94] Fix | Delete
$content=xyz_twap_post_to_smap_api($delete_entry_details, $url,$xyz_twap_xyzscripts_hash_val);
[95] Fix | Delete
echo $content;
[96] Fix | Delete
}
[97] Fix | Delete
}
[98] Fix | Delete
die();
[99] Fix | Delete
}
[100] Fix | Delete
[101] Fix | Delete
add_action('wp_ajax_xyz_twap_del_tw_entries', 'xyz_twap_del_entries_tw_fn');
[102] Fix | Delete
function xyz_twap_del_entries_tw_fn() {
[103] Fix | Delete
global $wpdb;
[104] Fix | Delete
if(current_user_can('administrator')){
[105] Fix | Delete
if($_POST){
[106] Fix | Delete
if (! isset( $_POST['_wpnonce'] )|| ! wp_verify_nonce( $_POST['_wpnonce'],'xyz_twap_del_entries_tw_nonce' ))
[107] Fix | Delete
{
[108] Fix | Delete
echo 1;die;
[109] Fix | Delete
}
[110] Fix | Delete
$tw_auth_id=$_POST['tw_auth_id'];
[111] Fix | Delete
$xyz_twap_xyzscripts_user_id = $_POST['xyzscripts_id'];
[112] Fix | Delete
$xyz_twap_xyzscripts_hash_val= $_POST['xyzscripts_user_hash'];
[113] Fix | Delete
$delete_entry_details=array('smap_tw_auth_id'=>$tw_auth_id,
[114] Fix | Delete
'xyzscripts_user_id' =>$xyz_twap_xyzscripts_user_id);
[115] Fix | Delete
$url=XYZ_TWAP_SMAPSOLUTION_AUTH_URL.'authorize-twitter/delete-tw-auth.php';
[116] Fix | Delete
$content=xyz_twap_post_to_smap_api($delete_entry_details, $url,$xyz_twap_xyzscripts_hash_val);
[117] Fix | Delete
echo $content;
[118] Fix | Delete
$result=json_decode($content);$delete_flag=0;
[119] Fix | Delete
if(!empty($result))
[120] Fix | Delete
{
[121] Fix | Delete
if (isset($result->status))
[122] Fix | Delete
$delete_flag =$result->status;
[123] Fix | Delete
}
[124] Fix | Delete
if ($delete_flag===1)
[125] Fix | Delete
{
[126] Fix | Delete
if ($tw_auth_id==get_option('xyz_twap_smapsoln_userid')){
[127] Fix | Delete
update_option('xyz_twap_smapsoln_secret_key', '');
[128] Fix | Delete
update_option('xyz_twap_smapsoln_userid', 0);
[129] Fix | Delete
}
[130] Fix | Delete
}
[131] Fix | Delete
}
[132] Fix | Delete
}
[133] Fix | Delete
die();
[134] Fix | Delete
}
[135] Fix | Delete
/////////////////////////////////////////////////////////////////////////////////////////////////////////
[136] Fix | Delete
?>
[137] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function