Closed dan-silk-discovery closed 8 years ago
The image URL I get already has %20 in it. I tried decoding that, but it didn't work. I then tried encoding the entire URL and that didn't work. The solution was to replace %20 with %2520 which seemed counter-intuitive to me, but if it works, it works.
I'm not sure if it's the same issue, but I spoke with @kentbrew on Twitter about problems with iOS Safari pinning, and I think he's resolved this problem.
I suspect it's the commas in the media URL, which are supposed to be percent-encoded when set as URL parameters. It sounds like you found an answer, so I'm going to close this.
I have this code below (modified to show values instead of variables). This works perfectly fine on a desktop browser, but devices with the Pinterest app don't work properly. I get
PinUtils.pinOne({ url: 'http://www.food.com/recipe/liisas-best-banana-nut-bread-79387?soc=socialsharingpinterest', media: 'http://img.sndimg.com/food/image/upload/h_240,w_320,fl_progressive,c_fit,q_92/v1/img/recipes/79/38/7/fhzY7SGQF23fNdrRMKfX_Banana%20Bread%201.jpg', description: 'Banana Nut Bread' })
It seems the problem is URLs with URL-encoded characters are breaking something in the app. The image doesn't show up in the example above.