where the images uploaded in tinymce are stored?

38 Views Asked by At

I have use tinyMCEeditor CDN in my laravel application

so i want to know, where the images uploaded in tinymce are stored?

file_picker_types: 'file image media',

        file_picker_callback: function (cb, value, meta) {
            var input = document.createElement('input');
            input.setAttribute('type', 'file');
            input.setAttribute('accept', 'image/*,audio/*,video/*');

            input.onchange = function () {
                var file = this.files[0];

                var reader = new FileReader();
                reader.onload = function () {
                    var id = 'blobid' + (new Date()).getTime();
                    var blobCache = tinymce.activeEditor.editorUpload.blobCache;
                    var base64 = reader.result.split(',')[1];
                    var blobInfo = blobCache.create(id, file, base64);
                    blobCache.add(blobInfo);

                    cb(blobInfo.blobUri(), {
                        title: file.name
                    });
                };
                reader.readAsDataURL(file);
            };

            input.click();
        },
1

There are 1 best solutions below

3
東雪蓮 On

I suggest you use ajax and upload the picture to the server.