Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 5    Views: 118

piggilypoo
Aspiring developer
Profile
Posts: 172
Reg: Jun 28, 2011
San Diego
5,120
04/11/15 09:48 PM (9 years ago)

How to link to a local image in Custom HTML w/ android studio?

In the past, using the custom HTML/text plugin, you could include an image in your BT_Docs folder by using something like img src="file:///android_asset/BT_Docs/appicon.jpg" However, that doesn't seem to work anymore. I even tried file:///assets/BT_Docs/appicon.jpg with no luck. Anyone have any ideas?
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
04/12/15 01:33 AM (9 years ago)
I always kept my images in the same directory, and called it locally... Tried just <img src="myimage.png"> in the same directory as the html file? Cheers! -- Smug
 
good
Code is Art
Profile
Posts: 2
Reg: Apr 12, 2015
from sunset
20
like
04/12/15 11:24 AM (9 years ago)
I love the design, but I do not know for programming
 
piggilypoo
Aspiring developer
Profile
Posts: 172
Reg: Jun 28, 2011
San Diego
5,120
like
04/12/15 11:33 AM (9 years ago)
@smug I'm talking about the Custom HTML/Text plugin, so there is no local directory
 
Becky
I hate code!
Profile
Posts: 269
Reg: Aug 08, 2012
NYC
6,140
like
04/12/15 02:49 PM (9 years ago)
 
piggilypoo
Aspiring developer
Profile
Posts: 172
Reg: Jun 28, 2011
San Diego
5,120
like
04/13/15 12:14 AM (9 years ago)
Maybe I needed to refresh the app or something but now it's working perfectly using file:///android_asset/BT_Docs/image.jpg. Does anyone know what the file path would be for an iOS app?
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.