HEX
Server: LiteSpeed
System: Linux standart108 4.18.0-553.121.1.lve.el8.x86_64 #1 SMP Thu Apr 30 16:40:41 UTC 2026 x86_64
User: pplae2ji7 (11089)
PHP: 8.3.33
Disabled: opcache_get_status
Upload Files
File: /var/www/vhosts/plasmak.com.tr/httpdocs/wp-content/themes/buliten/js/img_upload.js
(function($) {
    $('body').on('click','.experts_media_upload', function(e) {
        
        mediaImg = $(this).parent('p').find('img');
        mediaUrl = $(this).parent('p').find('.experts_media_url');

        e.preventDefault();
        var custom_uploader = wp.media({
            title: 'Select Image',
            button: {
                text: 'Use This Image',
            },
            library: {
                type: 'image'
            },
            multiple: false,
        })
        .on('select', function() {
            var attachment = custom_uploader.state().get('selection').first().toJSON();
            $(mediaImg).attr('src', attachment.url);
            $(mediaUrl).val(attachment.url);
        })
        .open();
    });


    $('body').on('click','.experts_media_upload_delete', function(e) {
        $(this).parent('p').find('img').attr('src', '');
        $(this).parent('p').find('.experts_media_url').val('');
    });


})(jQuery);