iOS Question WebView link not working with B4I 6.50

Pintinho

Member
Licensed User
Longtime User
Hi all
I have this very simple app that will call with webView an external booking system.

This app has been at the store for some time but I had to upgrade to IOS 13 SDK.

So I have recompiled with B4I 6.50, changed the version and uploaded again.

The app was rejected because the link within the webView (a call to privacy policy of the booking system) is not working - nothing happens.

This link works when I click from the Android version, so it is not a problem of the external booking system.

I there anything else I should be doing differently?

I have tried to create a new webview instead of using the existing one but the problem persisted.

Any help is really appreciated. Thanks!

(here's part of my code)

B4X:
'Code module


Sub Process_Globals
    'These global variables will be declared once when the application starts.
    'Public variables can be accessed from all modules.
    Public App As Application
    Public NavControl As NavigationController
    Private Page1 As Page

    
    Private btnReturn As Button
    Private pnlGoogleMap As Panel
    Private pnlMenu As Panel
    Private pnlWelcome As Panel
    Private WVGoogleMap As WebView
    Private WVSite As WebView
    
    Dim timerWelcomeScreen As Timer
    Dim counterWelcomeScreen As Int
    Dim HomeWebsite As String = "https://book.appointedd.com/app/5b23ccf61490f47e50695383"
    Dim WebCall As Application
    
    Private btnEmail As Button
    Private btnMap As Button
    Private btnPhone As Button
    Private imgMenu As ImageView
    
    'Private MapWidth As Int
    'Private MapHeight As Int
    Private btnWebsite As Button
End Sub

Private Sub Application_Start (Nav As NavigationController)
   
    NavControl = Nav
    Page1.Initialize("Page1")
    Page1.Title = "Bell Studios"
    Page1.RootPanel.Color = Colors.White
    Page1.RootPanel.LoadLayout("main")
    
    
    'Load the microsite
    WVSite.LoadUrl(HomeWebsite)

    WVGoogleMap.LoadUrl("https://www.google.co.uk/maps/place/Bell+Studios/@51.4988127,-0.2729622,15z/data=!4m5!3m4!1s0x0:0x3ff68778d5559c15!8m2!3d51.4988127!4d-0.2729622")
    
    'Set up the Welcome screen - Make sure the panel is visible, set counter to 0 and initialise timer
    timerWelcomeScreen.Initialize("timerWelcomeScreen", 900)
    counterWelcomeScreen = 0
    pnlWelcome.Visible = True
    timerWelcomeScreen.Enabled = True
    
    'Make sure panel is not showing
    pnlGoogleMap.Visible = False
    
    'Show screen
    NavControl.NavigationBarVisible = False
    NavControl.ShowPage(Page1)
    
End Sub

Private Sub Page1_Resize(Width As Int, Height As Int)
    
End Sub


Private Sub Application_Background
    
End Sub
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
So I have recompiled with B4I 6.50, changed the version and uploaded again.

The app was rejected because the link within the webView (a call to privacy policy of the booking system) is not working - nothing happens.
You shouldn't release the app without testing it.

Works fine here:
B4X:
Private Sub Application_Start (Nav As NavigationController)
    'SetDebugAutoFlushLogs(True) 'Uncomment if program crashes before all logs are printed.
    NavControl = Nav
    Page1.Initialize("Page1")
    Page1.Title = "Page 1"
    Page1.RootPanel.LoadLayout("1")
    NavControl.ShowPage(Page1)
    WebView1.LoadUrl("https://book.appointedd.com/app/5b23ccf61490f47e50695383")
End Sub

B4i_bRXGNjZdHC.png
 
Upvote 0

Pintinho

Member
Licensed User
Longtime User
Hi Erel
Thanks for checking into this.
And I did test but did not expect something not working on the external website.

And the link that is not reacting is a bit further down the booking system. If you keep selecting rooms and days (in the future, November 2020 since the studio is closed for now) and if you keep going through the booking, on the screen where it asks for your name, there is a link for the Privacy Policy, and nothing happens when you press that link.
 

Attachments

  • IMG_0043.PNG
    IMG_0043.PNG
    356 KB · Views: 206
Last edited:
Upvote 0

Pintinho

Member
Licensed User
Longtime User
Thanks, Erel!

Much cleaner option than before. Created new panel with another webview and added this bit of code.

B4X:
Sub WVSite_OverrideUrl (Url As String) As Boolean
    If Url= PrivacyWebsite Then
        WVPrivacy.LoadUrl(Url)
        pnlPrivacy.Visible = True
        Return True
    End If
    Return False
End Sub
 
Upvote 0
Top