cenyu Active Member Licensed User Longtime User Nov 23, 2017 #1 Hi friends, I have two html files in Files folder... I load file #1 into WebView. Into file #1 i have a link <a href='2.html'>open me</a> I trying to load file #2 into same WebView but there erro ocured WEB PAGE NOT FOUND! I try with this link <a href='file:///android_asset/2.html'>open me</a> - NOTHING!!!
Hi friends, I have two html files in Files folder... I load file #1 into WebView. Into file #1 i have a link <a href='2.html'>open me</a> I trying to load file #2 into same WebView but there erro ocured WEB PAGE NOT FOUND! I try with this link <a href='file:///android_asset/2.html'>open me</a> - NOTHING!!!
cenyu Active Member Licensed User Longtime User Nov 23, 2017 #2 Oh no i forgot to switch into Release mode...Everything work perfect! Upvote 0
M megzz Member Licensed User Longtime User Nov 23, 2017 #3 yes ... you release app in debug mode and this mode ,app can't access to asset folder . Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Nov 24, 2017 #5 megzz said: and this mode ,app can't access to asset folder . Click to expand... That's not the correct answer. You should use WebViewAssetFile method to get a url to the asset resource: https://www.b4x.com/android/forum/t...es-in-the-assets-directory.69996/#post-444559 Also available with XUI.FileUri. Upvote 0
megzz said: and this mode ,app can't access to asset folder . Click to expand... That's not the correct answer. You should use WebViewAssetFile method to get a url to the asset resource: https://www.b4x.com/android/forum/t...es-in-the-assets-directory.69996/#post-444559 Also available with XUI.FileUri.