Server: news.mantaraham.ir
Current directory: /home/mantaraham/public_html/news/wp-content/plugins/captcha-bws/bws_menu
Software: LiteSpeed



Shell Command Create a new file Upload file

File: deactivation-form.php
' ) + ''; _parent.append( $( reasonInputHtml ) ); _parent.find( 'input, textarea' ).attr( 'placeholder', _parent.data( 'input-placeholder' ) ).focus(); if ( BwsModalIsReasonSelected( 'OTHER' ) ) { \$modal.find( '.message' ).text( '" . __( 'Please tell us the reason so we can improve it.', 'bestwebsoft' ) . "' ).show(); } } }); /* If the user has clicked outside the window, cancel it. */ \$modal.on( 'click', function( evt ) { var \$target = $( evt.target ); /* If the user has clicked anywhere in the modal dialog, just return. */ if ( \$target.hasClass( 'bws-modal-body' ) || \$target.hasClass( 'bws-modal-footer' ) ) { return; } /* If the user has not clicked the close button and the clicked element is inside the modal dialog, just return. */ if ( ! \$target.hasClass( 'bws-modal-button-close' ) && ( \$target.parents( '.bws-modal-body' ).length > 0 || \$target.parents( '.bws-modal-footer' ).length > 0 ) ) { return; } /* Close the modal dialog */ \$modal.removeClass( 'active' ); $( 'body' ).removeClass( 'has-bws-modal' ); return false; }); } function BwsModalIsReasonSelected( reasonID ) { /* Get the selected radio input element.*/ return ( reasonID == \$modal.find('input[type=\"radio\"]:checked').val() ); } function BwsModalReset() { selectedReasonID = false; /* Uncheck all radio buttons.*/ \$modal.find( 'input[type=\"radio\"]' ).prop( 'checked', false ); /* Remove all input fields ( textfield, textarea ).*/ \$modal.find( '.bws-modal-reason-input' ).remove(); \$modal.find( '.message' ).hide(); /* Hide, since by default there is no selected reason.*/ \$anonymousFeedback.hide(); BwsModalDisableDeactivateButton(); BwsModalShowPanel(); } function BwsModalEnableDeactivateButton() { \$modal.find( '.bws-modal-button-deactivate' ).removeClass( 'disabled' ).show(); \$modal.find( '.bws-modal-processing' ).hide(); } function BwsModalDisableDeactivateButton() { \$modal.find( '.bws-modal-button-deactivate' ).addClass( 'disabled' ); } function BwsModalShowPanel() { \$modal.find( '.bws-modal-panel' ).addClass( 'active' ); } })(jQuery);"; } /* add script in FOOTER */ wp_register_script( 'bws-deactivation-feedback-dialog-boxes', '', array( 'jquery' ), false, true ); wp_enqueue_script( 'bws-deactivation-feedback-dialog-boxes' ); wp_add_inline_script( 'bws-deactivation-feedback-dialog-boxes', sprintf( $script ) ); } } /** * Called after the user has submitted his reason for deactivating the plugin. * * @since 2.1.3 */ if ( ! function_exists( 'bws_submit_uninstall_reason_action' ) ) { function bws_submit_uninstall_reason_action() { global $bstwbsftwppdtplgns_options, $wp_version, $bstwbsftwppdtplgns_active_plugins, $current_user; wp_verify_nonce( $_REQUEST['bws_ajax_nonce'], 'bws_ajax_nonce' ); $reason_id = isset( $_REQUEST['reason_id'] ) ? stripcslashes( sanitize_text_field( $_REQUEST['reason_id'] ) ) : ''; $basename = isset( $_REQUEST['plugin'] ) ? stripcslashes( sanitize_text_field( $_REQUEST['plugin'] ) ) : ''; if ( empty( $reason_id ) || empty( $basename ) ) { exit; } $reason_info = isset( $_REQUEST['reason_info'] ) ? stripcslashes( sanitize_text_field( $_REQUEST['reason_info'] ) ) : ''; if ( ! empty( $reason_info ) ) { $reason_info = substr( $reason_info, 0, 255 ); } $is_anonymous = isset( $_REQUEST['is_anonymous'] ) && 1 == $_REQUEST['is_anonymous']; $options = array( 'product' => $basename, 'reason_id' => $reason_id, 'reason_info' => $reason_info, ); if ( ! $is_anonymous ) { if ( ! isset( $bstwbsftwppdtplgns_options ) ) $bstwbsftwppdtplgns_options = ( is_multisite() ) ? get_site_option( 'bstwbsftwppdtplgns_options' ) : get_option( 'bstwbsftwppdtplgns_options' ); if ( ! empty( $bstwbsftwppdtplgns_options['track_usage']['usage_id'] ) ) { $options['usage_id'] = $bstwbsftwppdtplgns_options['track_usage']['usage_id']; } else { $options['usage_id'] = false; $options['url'] = get_bloginfo( 'url' ); $options['wp_version'] = $wp_version; $options['is_active'] = false; $options['version'] = $bstwbsftwppdtplgns_active_plugins[ $basename ]['Version']; } $options['email'] = $current_user->data->user_email; } /* send data */ $raw_response = wp_remote_post( 'https://bestwebsoft.com/wp-content/plugins/products-statistics/deactivation-feedback/', array( 'method' => 'POST', 'body' => $options, 'timeout' => 15, ) ); if ( ! is_wp_error( $raw_response ) && 200 == wp_remote_retrieve_response_code( $raw_response ) ) { if ( ! $is_anonymous ) { $response = maybe_unserialize( wp_remote_retrieve_body( $raw_response ) ); if ( is_array( $response ) && ! empty( $response['usage_id'] ) && $response['usage_id'] != $options['usage_id'] ) { $bstwbsftwppdtplgns_options['track_usage']['usage_id'] = $response['usage_id']; if ( is_multisite() ) update_site_option( 'bstwbsftwppdtplgns_options', $bstwbsftwppdtplgns_options ); else update_option( 'bstwbsftwppdtplgns_options', $bstwbsftwppdtplgns_options ); } } echo 'done'; } else { echo $response->get_error_code() . ': ' . $response->get_error_message(); } exit; } } add_action( 'wp_ajax_bws_submit_uninstall_reason_action', 'bws_submit_uninstall_reason_action' );