HEX
Server: Apache
System: Linux srv-plesk28.ps.kz 5.14.0-284.18.1.el9_2.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Jun 29 17:06:27 EDT 2023 x86_64
User: greencl1 (10085)
PHP: 8.1.33
Disabled: apache_setenv,dl,eval,exec,openlog,passthru,pcntl_exec,pcntl_fork,popen,posix_getpwuid,posix_kill,posix_mkfifo,posix_setpgid,posix_setsid,posix_setuid,proc_close,proc_get_status,proc_nice,proc_open,proc_terminate,shell_exec,socket_create,socket_create_listen,socket_create_pair,syslog,system,socket_listen,stream_socket_server
Upload Files
File: /var/www/vhosts/greenclinic.kz/newsite/wp-content/plugins/cf7-telegram/js/admin.js
cf7tg = {
	
	init : function(){
		jQuery( '.wpcf7tg_notice' ).each( function( index, notice ){ 
			var panel = jQuery( notice );
			panel.on( 'click', '.buttons a', { chat : panel.data( 'chat' ) }, function( e ){
				var btn = jQuery( this );
				if ( ! confirm( wpData.l10n['confirm_' + btn.data('action') ] ) ) return;
				var postdata = {
					action		: 'wpcf7_tg',
					_wpnonce	: wpData.nonce,
					do_action	: btn.data( 'action' ),
					chat		: e.data.chat
				}
				
				jQuery.post( wpData.ajax, postdata, function( response ) {
					var result = JSON.parse( response );
					if ( true == result.result ) {
						var panel = jQuery( '.wpcf7tg_notice[data-chat="' + result.chat + '"]' );
						panel.attr( 'status', result.new_status );
					}
				});
			} );
		} );
	}
	
}

jQuery( document ).ready( function(){
	cf7tg.init();
});