django-ckeditor-filebrowser-filer icon indicating copy to clipboard operation
django-ckeditor-filebrowser-filer copied to clipboard

pdf upload

Open openHBP opened this issue 7 years ago • 6 comments

Extremely nice package. I find it very usefull when we use Django CMS using Filer for Document management. I've implemented your package to be able to use the same for image selection at frontend but I'm facing a problem for pdf and document management. Are you planning to implement it? Or do you have a simple alternative? Regards

openHBP avatar Jan 19 '18 13:01 openHBP

Thanks :) What's the issue with PDF? It should work out of the box

yakky avatar Jan 19 '18 13:01 yakky

I'm with django 1.8 with last version of your package and Pillow 5.0.0. When I select a pdf file on the filerImageDialog, the canonical URL is not comming back in the URL field of the the Image Property window. imagepropertyurl

openHBP avatar Jan 19 '18 13:01 openHBP

The error I get is the same as the one mentionned on issue 28.

File "C:\venvpy\vvcp\lib\site-packages\ckeditor_filebrowser_filer\views.py", line 101, in url_image 'width': image.width, AttributeError: 'File' object has no attribute 'width'

When I comment the 2 lines:

    data = {
        'url': url,
#         'width': image.width,
#         'height': image.height,
    }

The canonical URL is well written into URL field but the Image Property Windows mention : "No file selected" (see PrintScreen in French) image

And I get the folowwing error:

[19/Jan/2018 15:05:49] "GET /fr/favicon.ico/ HTTP/1.1" 404 12127 [19/Jan/2018 15:05:51] "GET /filebrowser_filer/url_image/355/ HTTP/1.1" 200 43 [19/Jan/2018 15:05:51] "GET /filer/canonical/1516272478/355/ HTTP/1.1" 302 0 [19/Jan/2018 15:05:52] "GET /media/filer_public/d2/3b/d23b167e-eab4-42b2-b583-6ff5f50df0f1/rapport_final_de_projet_rqd_cp_complet.pdf HTTP/1.1" 200 73728 Traceback (most recent call last): File "c:\python35\Lib\wsgiref\handlers.py", line 138, in run self.finish_response() File "c:\python35\Lib\wsgiref\handlers.py", line 180, in finish_response self.write(data) File "c:\python35\Lib\wsgiref\handlers.py", line 279, in write self._write(data) File "c:\python35\Lib\wsgiref\handlers.py", line 453, in _write result = self.stdout.write(data) File "c:\python35\Lib\socket.py", line 593, in write return self._sock.send(b) ConnectionAbortedError: [WinError 10053] Une connexion établie a été abandonnée par un logiciel de votre ordinateur hôte [19/Jan/2018 15:05:52] "GET /media/filer_public/d2/3b/d23b167e-eab4-42b2-b583-6ff5f50df0f1/rapport_final_de_projet_rqd_cp_complet.pdf HTTP/1.1" 500 59

Exception happened during processing of request from ('127.0.0.1', 53384)

openHBP avatar Jan 19 '18 14:01 openHBP

Thanks for the detailed report, we will investigate on the issue

yakky avatar Jan 19 '18 14:01 yakky

Any update on this?

tehfink avatar Sep 13 '18 11:09 tehfink

Hello yakky, I'm still stuck with this issue. The only thing I would like to do is to access filer files (images & documents) from a "CKEditor like" window. Is it now feasible with cms.models.fields.PlaceholderField? I've tried to implement without any success. Would you please take a look to my question on stackoverflow?

openHBP avatar Jul 29 '20 09:07 openHBP