Android Question punycode and webview

barko

Member
Licensed User
Longtime User
Hi,
i have this code, it do not work if i use punycode like xn--strenik-gxb.net, but it works ok if i use normal domain name like aservis.si or some other.

...
spletnastran="xn--strenik-gxb.net"
...

Sub JobDone (job1 As HttpJob)
If job1.JobName="Job1" And job1.Success=True Then
WebView1.LoadUrl("http://" & spletnastran)
Else
Msgbox2("Error loading website",spletnastran,"ok","","",Null)
ExitApplication
End If
End Sub

Any suggestion how to fix this?

Thanks in advance!

I try this with my copy of b4a (4.30) and with b4a trial latest version, same result.
 

DonManfred

Expert
Licensed User
Longtime User
have you tried to use
B4X:
dim url as String = "https://strežnik.net/"
 
Upvote 0

barko

Member
Licensed User
Longtime User
Yeah, I discover something else now, webview works ok, but i have this code too in app and I now believe that is HttpJob problematic.

here job try to download site, and if spletnastran has punycode in it, it fails to download

B4X:
     job.Initialize("Job1",Me)
     job.Download("http://" & spletnastran)

so webview it self works ok

i should check online status on different way i think

using HttpUtils2 v2.01
 
Last edited:
Upvote 0
Top