From the camera roll, I get a list of URIs in the ph://xxxxx format.
If I use these URIs in Image or ImageBackground components everything works as expected.
I want to show these photos in a webview. Adding to the html an img tag with that kind of URI doesn't work.
Am I missing something?
Is there any workaround to display such images in a webview?
For anyone interested, after trying various solutions, it doesn't seem to work at the time of writing.
I solved getting the absolute path of the image, which in my case meant copying the file from the cameraroll to the app document directory.
Related
I have no idea why Webstorm is not finding my pictures all ways to import the pictures but The simulator are telling me that none of my files exist
Don't worry about this. Editors generally don't suggest images while writing paths.
Just remove the import statement and directly access the image in the Image tag.
like this,
<Image source={require('./src/resources/images/Logo.png')}/>
I have been trying to replace my carrousel images with t new photos from my phone camera or album, but for some binding reason, they don't display on the carousel.
I am using Xamarin Media Plugin.
any picture I select should display on the carousel. I have been trying everything in here. IMAGE URL works fine, stored images in the resources folder, works as well. but, for some reason display the images from the media is been a nightmare.
You can clone my sample project # GITHUB
I will appreciate Any help.
Looking at the GITHUB project, easy to understand why no relevant code here, it will require the whole sample project. It seems the carousel is not getting updated when uploading an image, binding?? I am still checking.
I am trying to display a static image(ic_launcher) in my android app using react native. I am getting a black response. No errors. Just a blank view as though the resource doesn't exist.I am able to display images from the network.
Your ic_launcher files are probably placed in android/app/src/main/res/mipmap-xxx directories. Try to move it to android/app/src/main/res/drawable-xxx directories.
\android
|----\app
|----|---\src
|----|---|----\main
|----|---|----|---\res
|----|---|----|---|---\drawable
|----|---|----|---|---|---\ic_launcher.png
You should use require('image!img_name') as a source attribute of Image component.
See example app here https://github.com/facebook/react-native/blob/master/Examples/UIExplorer/ImageExample.js#L84 with it's resource placed under https://github.com/facebook/react-native/tree/master/Examples/UIExplorer/android/app/src/main/res/drawable
I replaced the original images with my own images in the simple-slider-source.html file in the non-jquery example folder and uploaded into the server along with the image folder and .js files but it doesn't work. It just running the slider without the images. Before uploading into my server, I have compiled it with the simple-slider.compress batch file. In case of original images it's working fine but not with the replaced images.
Is there anybody who can suggest any clue why it is happening and how to fix it? Providing sourcecode snippet would be much appreciated.
The src attribute (url) of the <img> element is incorrect.
I've been trying to get my app's tile to display an image from the web, but couldn't get it to work. I then tried the Tiles and Badges app sample, where in scenario 3 you can send a tile notification that uses a web image. No matter which image url I paste in the text box, the tile refuses to get updated. So apparently, the sample isn't working either, or something is very wrong.
The images are all smaller than 1024x1024 and less than 200KB. Fun fact: if I download one of the images I unsuccesfully tried to feed the sample, add it to the project and then send a notification using it as a local image, the tile gets updated. So apparently the image isn't the problem.
Has anybody been able to get this working? I don't get what I'm doing wrong.
Do have internet permission ticket in app manifest? Maybe only your app dont have permission to download your image from web.