I noticed that the following file from a website could compress the image depending on the size passed as parameters in the url.
This is the following url.
https://images.pexels.com/photos/207301/pexels-photo-207301.jpeg
and when passed as a parameter :
https://images.pexels.com/photos/207301/pexels-photo-207301.jpeg?w=440&auto=compress&cs=tinysrgb
it gives a smaller image.
Now what I did:
I downloaded the image uploaded it to my website:
http://auraquotes.com/images/pexels-photo-207301.jpeg
I also tried passing the parameters: http://auraquotes.com/images/pexels-photo-207301.jpeg?w=440&auto=compress&cs=tinysrgb
but nothing happened.
I wonder the reason?
That website is running a solution called imgix which handles the image request and the compression. Without imgix installed, you won't get the same effect.
Related
Playground Test Link
When I use the local Images with (~), it is working. But when I change the relative path to URL(https://via.placeholder.com/150.jpg), it throws an error.
It is working for https://nativescript.org/assets/ns-logo_share_600x315.png but not for https://via.placeholder.com/150.jpg or https://via.placeholder.com/150.png or any else. How can I set it so that it can accept images from any server? Is it supposed to be a server related issue as I checked the headers and mostly all are the same.
As per the docs, we can dd URLs to Image tag but it is still not working. Please help me rectify this issue.
Error
[Galaxy Note8]: Error in downloadBitmap -
java.io.FileNotFoundException: https://via.placeholder.com/150.png
Tried all file types: jpg, png, jpeg, gif
This is an example for an image that I add to the image_urls field.
http://static.zara.net/photos//2014/I/0/2/p/5875/309/800/2/w/1920/5875309800_1_1_1.jpg
Yet I get this warning and the image is not uploaded.
[zara_com] WARNING: File (code: 404): Error downloading image from http://static.zara.net/photos//2014/I/0/2/p/5875/309/800/2/w/1920/5875309800_1_1_1.jpg> referred in
Though an image like this one:
http://static.zara.net/photos//2014/V/1/3/p/1280/303/105/2/w/1920/1280303105_2_1_1.jpg
is uploaded normally.
What might be the problem? what should I check?
As far as I can see, they seem to be filtering requests made with the default scrapy user agent:
'User-Agent': 'Scrapy/0.24.2 (+http://scrapy.org)'
When I changed the USER_AGENT setting in settings.py of my project, it started returning 200 on all requests. The strange thing is that before that it returned 404 even on the image, which you said is returned normally.
P.S. It's not very good to scrape content from a site, if they are not allowing it, but well it's not like they are disallowing it in their robots.txt. Still you should probably enable the RobotsTxtMiddleware and the AutoThrottle extension to ensure you are playing fairly.
I have a scenario of uploading a product image . I recorded the scenario using proxy server
but the image is not uploaded. I tried by moving the images to the bin folder and then did the same still the image is not uploaded. Can anyone help me to rectify this issue.
My code is :
Send parameter with request
Name Value
_method POST
Send files with request
file path Parameter name MIME type
C:/loc/jmeter/bin/img.jpg data[Product][product_image] image/jpeg
Actually the problem is with the HTTP Requests Path because when i add an image using proxy server
HTTP Requests
Server Name: Server.com
path:/products/image/1147
Using the same path i was not able to upload images but when i change the
" path:/products/image/1148 "
Was able to upload image but every time i cant change this.
Is there any way to automate it.
Please help me..
Make sure that you have following configuration:
POST method is selected from drop-down.
2.Use multipart/form-data for POST box checked
Parameter name exactly matches relevant input of type "file" at upload page
Any other correlation and session attributes are fine, i.e. session ID, cookies, etc.
Also it worth checking jmeter.log and log of your web/application server or proxy for any errors.
See Upload and Download Scenarios with Apache JMeter guide for more details.
I am having an issue uploading images but clearing the image search path is not working to solve my issue. (Found in another post)
This is the error i get:
Image attributes processor v1.0.25 - error copying media/catalog/product/5/4/54402.jpg : download error,URL cmsdistribution.com/product-files/image/54402.jpg is unreachable
Image attributes processor v1.0.25 - error copying media/catalog/product/5/4/54402.jpg : download error,URL cmsdistribution.com/product-files/image/54402.jpg is unreachable
Image attributes processor v1.0.25 - error copying media/catalog/product/5/4/54402.jpg : download error,URL cmsdistribution.com/product-files/image/54402.jpg is unreachable
The media/catalog/product folder and everything below is set to 777 and the URL i am calling in the csv looks fine and i can find it in a simple browser (Seen 3 times above (once for image, small_image and thumbnail with the only other column in the sheet being sku))
Has anyone else played with image importing? Am i missing something?
I have had to remove the http www dot etc from the codes above as i am being caught out for spamming in the post
Try using the latest svn version of Magmi. The image processor had a "bug" for handling redirected images (checking only 200 response on HEAD request for download check).
The latest svn version has a fix for this.
I have an mp3 file in an S3 bucket. I am fetching this file via ajax GET request for html5 audio playback. Intermittently, the get request will fail to download the file and thus the track will not play. The request returns "206 partial content." Oddly, it will work several times before failing and then continuing to fail.
If I disable caching in my browser (chrome), the file will download and play appropriately.
Have I configured s3 incorrectly? How can I get this mp3 file to download and play consistently?
specific file is located here: https://s3.amazonaws.com/1m40s_dev/assets/music/walden.mp3
thanks!
I've found this often relates to the MIME type set on the S3 hosted file.
Setting the correct MIME type seems to fix things.
On a side note, I struggled with a single binary file always breaking in IE. Its MIME type was application/octet-stream. I changed the MIME to binary/octet-stream and that seemed to fix downloads from IE. Not sure why.
use amazon cloudfront solve the problem
I solved this by appending a timestamp to the end of the mp3 url on page load. This forced a new download of the content each time and eliminated the caching error.
This feels more like a work around than a fix. I still don't know the root cause of the issue but if you find yourself having a similar problem and just need to move on, add a timestamp or random number as a param at the end of the url
.../assets/music/walden.mp3?[timestamp]
One other workaround I've found is, if you're using rails, turning off turbolinks makes this go away on chrome. I'll add more to my answer as I discover more.