How to Crop Multiple Uploads with Image Preview in Laravel 9? - repository-pattern

I'm attempting to create a form in Laravel 9 (Repository pattern) that allows me to upload multiple images and preview them before allowing the user to crop the image and save both files (original and cropped).
Do you have any suggestions for how to approach this?

I guess you would need a combination of frontend javascript and fileupload on the laravel side. For javascript, you can look at filepond.
Alternatively, you can look at laravel filament. Filament is already using filepond as part of its form builder. It allows multiple files upload and resizing. Maybe you can start your approach from there.

Related

How can I create a video and photo uploading feature on my website using Python and Django?

How can I create a video and photo uploading feature on my website using Python and Django?
I have using forms,models(file_field) and yet it doesn't render to the front_end
If you're using ImageField to upload to the server, make sure you have pillow installed. Your python may just be looking at a wrong path to search for your files. Secondly, you might want to consider your markup code, and make sure that there is space for your video to be uploaded. ie) , etc..

Django - how to render all pages of pdf files at once

I am trying to make a pdf viewer in HTML template using pdf.js in Django framework.
I had used a code that I got from a Youtube channel Traversy Media on how to create a custom PDF Viewer With JavaScript. It is working but I want to know if it's possible to render all pages at once.
Here's the link of the pdf.js full code in GitHub...
Is there an alternative way rather than sticking to this code?

django-cms picture plugin - bulk upload

What would be the best way to make it possible to upload many pictures at once to some cms page? or alternatively, how can I change the admin template/view to make it work?
is there a nice way to achieve it?
(I'm working withe the default picture plugin)
picture plugin does not support multiple uploads. why don't you use gallery plugin? where you can add many images at once.

Django image insertion in Admin

I am building a small side project - a simple news site. I want to use the Django Admin for uploading articles and allow access to non-coders so as they can publish articles a la Wordpress or such. I have added some functionality to the admin, first trying out TinyMCE and Dojo rich text editors. However, these do not come with the ability to insert an image into an article from a file (just urls).
I really only want some light text formatting in the text area plus the ability to upload and insert images from the users's harddrive directly into the article. Is there a simple way to achieve this?
If you are already using django-tinymce, you can integrate django-filebrowser with it. See django-tinymce's documentation.
There is also a commercial choice which looks good, but I have never tested it.

Django Bulk Zip upload

I want to upload images to a gallery app. I want the user to be able to either load images normaly, or upload on zip file containing all the images for that gallery. Then it must be uncompressed and all images must be added to that model. This is for the admin site.
Any ideas?
You could either use the existing django-app django-photologue which enables you to do that or have a look at how it is implemented there: https://code.google.com/p/django-photologue/source/browse/trunk/photologue/models.py.
If you see that photlogue is lacking some of the functionality you need, you could also subclass and extend photologue's models in your app!