I'm using "standalone button" for many pages on website (product/create.blade.php, banner/create.blade.php, ...)
$('#lfm').filemanager('image');
And i also call an image handler event after the image is uploaded,
based on the answer of Sti3bas: https://laracasts.com/discuss/channels/tips/resize-and-optimize-images-upon-upload-with-laravel-filemanager
But all uploaded images are resized, i just want the images of the product to change, so is there any way to determine the image uploaded from the product/create.blade.php page in the "ResizeUploadedImage" event.
Related
I'm trying to make some automatic captcha input systems (recognition of figures in captcha image by deep learning and input the figure automatically)
.
For that, the captcha image should be inputted to some deep learning system.
The captcha image in some online web page is in the img src but the src is not ending with some file extension like jpg, png..
It look like the below(it is an example).
img src="/nn/mm/captchaimg?/kk=image"
The above image shown in the web browser is changing after some time periods(about 1,2 min).
If the web including the above image is reloaded, the captcha is changed to another captcha image
(It means that in web crawler, the image is changed to by each request to server).
How to save the above image which has the above special properties in html in crawler?
I'm now doing it with goquery in Golang.
I should do
Saving the captcha image in the web page got by requesting in crawler.
Getting the figures in the above captcha image using my deep learning system.
Input the figures to the form in the above web page in step 1(with maintaining the session, reload or retry of requesting should not be done) and submit
I have done deep learning system in Step 2(test be done, it works well).
But I have no idea of Step 1, 3.
Any advice will be helpful to me.
Thank you in advance.
There are lots of documents about downloading the image in golang crawlier.
But I cannot find the methods to download the images changing by requesting the image URL
(I want to download the first image when I request the web page including the image at first time).
I am trying to build a page to register a user. On the page I need the user to upload a profile image. After uploading,the user should be required to crop the image. There are also additional things for the user to input on the page like email, name etc..
So far I have put the upload component, the cropper and all the other inputs in the same h:form. I am using the image uploader in "auto" mode. After uploading, the cropper automatically displays the uploaded image and the cropper region appears.
However, the cropper action method does not get invoked when I click Crop.A "conversion error{0}" is displayed in the growl on the screen.
This error appears even if the Crop() method is completely empty.
I am not sure what I am doing wrong..please could someone advise?
I'm running a Vanilla Forum with a FileUpload plugin, allowing users to upload images and insert the corresponding code directly into the body of their post. These images work with FancyBox when clicked, linking together nicely within the page. However, should a user use a third-party image hosting site (i.e. Imagevenue, Imageshack, Postimage.org) and copy and paste the resulting image code, it deactivates the FancyBox feature associated with all images previously on the page, so when you click on an image uploaded via FileUpload it opens in a new window now instead of in a FancyBox.
My question is one of two things:
a) Is it possible to fix this formatting issue so that if a user does choose to use a third-party image hosting service then it will not affect the fancybox of my previous images.
or
b) Is it possible to block this type of image code from being inputted in the body of a post to prevent this from ever happening.
Thank you and please reply if you would like more information!
Most likely the generated code from those third-party hosting sites has not an image extension (JPG, PNG, GIF) so fancybox doesn't know what type of content needs to handle.
If you are binding fancybox like
$(".fancybox").fancybox();
... you could force the type of content to image like
$(".fancybox").fancybox({
type : "image"
});
I don't really see how pasting the code of a new image will disable the code for existing ones if you want to elaborate.
I am new HTML5 and Ajax and I was wonder if it's possible with these technologies to write a service that would allow a user to upload an image for example in the background so they could continue browsing different pages on the same site while the upload is in progress?
XHR2 AJAX request can submit binary data like images:
https://developer.mozilla.org/en-US/docs/Using_files_from_web_applications#Example.3A_Uploading_a_user-selected_file
However, changing the address bar (windows.location) will interrupt the upload as the new page is loaded. You can work around of this by loading pages via AJAX and using History API:
https://developer.mozilla.org/en-US/docs/DOM/Manipulating_the_browser_history
Optionally you can resize image on the client-side using <canvas> to decrease the needed bandwidth and the server load
Resizing an image in an HTML5 canvas
Also if you touch the image in <canvas> you might want to keep JPEG metadata, like rotation and GPS coordinates around,
https://github.com/miohtama/Krusovice/blob/master/src/tools/resizer.js
I have a problem with images in my web app. let say I have a form where there are some text fields, dropdowns, upload ajax control for multiple image upload and button Save.
I know how to upload images and posting a form and saving everything to database but the problem is that I want to achieve the following user experience:
User can upload multiple images and browser after successful upload shows thumbnail (this I know how to do it)...the problem here is that I do not want to save images to db before button save is pressed. Is there any convinient how to save temporary images...I have tried temp table which after button is pressed, copies all images to image table but here is browser refresh problem that looses all the data and images stay in a temp table. Can you use a session for storing temporary images or any other way (I think session is not particulary good idea for such things.)
One easy way to achieve that is to use the HTML5 File API and display a thumbnail once the user selects a file to upload. You don't even need to waste bandwidth as everything happens on the client. Once the user submits the form, then the image will be uploaded to the server.
Another possibility is to use one of the gazillions of available AJAX upload controls such as Uploadify, Valums Ajax Upload, Uploadify, the jQuery form plugin, ... which will allow you to upload the file to the server using an AJAX request so that you can resize it there and return the resized image to the client that you could display the thumbnail on the client.