HEX
Server: nginx/1.16.1
System: Linux iZ7xv2zauie3qihz0jlnrxZ 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User: www (1000)
PHP: 7.2.33
Disabled: passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
Upload Files
File: /www/wwwroot/shzthfdcpg.com/wp-content/plugins/wp-user-avatar/js/wp-user-avatar.js
(function($) {
	var id;
    wp.media.wpUserAvatar = {
		
        get: function() {
            return wp.media.view.settings.post.wpUserAvatarId
        },
        set: function(a) {
            var b = wp.media.view.settings;
            b.post.wpUserAvatarId = a;
            b.post.wpUserAvatarSrc = $('div.attachment-info').find('img').attr('src');
            if (b.post.wpUserAvatarId && b.post.wpUserAvatarSrc) {
                $('#wp-user-avatar'+id).val(b.post.wpUserAvatarId);
                $('#wpua-images'+id+', #wpua-undo-button'+id).show();
                $('#wpua-preview'+id).find('img').attr('src', b.post.wpUserAvatarSrc).removeAttr('height', "");
                $('#wpua-remove-button'+id+', #wpua-thumbnail'+id).hide();
                $('#wp_user_avatar_radio').trigger('click')
            }
            wp.media.wpUserAvatar.frame().close()
        },
        frame: function() {
            if (this._frame) {
                return this._frame
            }
            this._frame = wp.media({
                library: {
                    type: 'image'
                },
                multiple: false,
                title: $('#wpua-add'+id).data('title')
            });
            this._frame.on('open', function() {
                var a = $('#wp-user-avatar'+id).val();
                if (a == "") {
                    $('div.media-router').find('a:first').trigger('click')
                } else {
                    var b = this.state().get('selection');
                    attachment = wp.media.attachment(a);
                    attachment.fetch();
                    b.add(attachment ? [attachment] : [])
                }
            }, this._frame);
            this._frame.state('library').on('select', this.select);
            return this._frame
        },
        select: function(a) {
            selection = this.get('selection').single();
            wp.media.wpUserAvatar.set(selection ? selection.id : -1)
        },
        init: function() {
            $('body').on('click', '#wpua-add', function(e) {
                e.preventDefault();
                e.stopPropagation();
				id='';
                wp.media.wpUserAvatar.frame().open()
            })
            $('body').on('click', '#wpua-add-existing', function(e) {
                e.preventDefault();
                e.stopPropagation();
				id='-existing';
                wp.media.wpUserAvatar.frame().open()
            })
        }
    }
})(jQuery);
jQuery(function($) {
    if (typeof(wp) != 'undefined') {
        wp.media.wpUserAvatar.init()
    }
    $('#your-profile').attr('enctype', 'multipart/form-data');
    var a = $('#wp-user-avatar').val();
    var b = $('#wpua-preview').find('img').attr('src');
    $('body').on('click', '#wpua-remove', function(e) {
        e.preventDefault();
        $('#wpua-original').remove();
        $('#wpua-remove-button, #wpua-thumbnail').hide();
        $('#wpua-preview').find('img:first').hide();
        $('#wpua-preview').prepend('<img id="wpua-original" />');
        $('#wpua-original').attr('src', wpua_custom.avatar_thumb);
        $('#wp-user-avatar').val("");
        $('#wpua-original, #wpua-undo-button').show();
        $('#wp_user_avatar_radio').trigger('click')
    });
    $('body').on('click', '#wpua-undo', function(e) {
        e.preventDefault();
        $('#wpua-original').remove();
        $('#wpua-images').removeAttr('style');
        $('#wpua-undo-button').hide();
        $('#wpua-remove-button, #wpua-thumbnail').show();
        $('#wpua-preview').find('img:first').attr('src', b).show();
        $('#wp-user-avatar').val(a);
        $('#wp_user_avatar_radio').trigger('click')
    })
});
jQuery(function($) {
    if (typeof(wp) != 'undefined') {
        wp.media.wpUserAvatar.init()
    }
    $('#your-profile').attr('enctype', 'multipart/form-data');
    var a = $('#wp-user-avatar-existing').val();
    var b = $('#wpua-preview-existing').find('img').attr('src');
    $('body').on('click', '#wpua-remove-existing', function(e) {
        e.preventDefault();
        $('#wpua-original-existing').remove();
        $('#wpua-remove-button-existing, #wpua-thumbnail-existing').hide();
        $('#wpua-preview-existing').find('img:first').hide();
        $('#wpua-preview-existing').prepend('<img id="wpua-original-existing" />');
        $('#wpua-original-existing').attr('src', wpua_custom.avatar_thumb);
        $('#wp-user-avatar-existing').val("");
        $('#wpua-original-existing, #wpua-undo-button-existing').show();
        $('#wp_user_avatar_radio').trigger('click')
    });
    $('body').on('click', '#wpua-undo-existing', function(e) {
        e.preventDefault();
        $('#wpua-original-existing').remove();
        $('#wpua-images-existing').removeAttr('style');
        $('#wpua-undo-button-existing').hide();
        $('#wpua-remove-button-existing, #wpua-thumbnail-existing').show();
        $('#wpua-preview-existing').find('img:first').attr('src', b).show();
        $('#wp-user-avatar-existing').val(a);
        $('#wp_user_avatar_radio').trigger('click')
    })
});