Just starting out? Need help? Post your questions and find answers here.
Dirk Geppert
 
Posts: 5
Joined: Fri Sep 22, 2017 7:02 am

Problem with Safari on iPhone

by Dirk Geppert Thu Oct 12, 2017 2:24 pm

I hope SpiderBasic is also suitable for mobile devices? I have created a small webapp and can't use it with the iPhone browser. When you click in an input field everything disappears.

You can also test it here as well: http://h2717740.stratoserver.net/amount/

Code: Select all
Enumeration FormWindow
  #hWnd
EndEnumeration

Enumeration FormGadget
  #D_DATE
  #S_TITLE
  #S_AMOUNT
  #T_DATE
  #T_TITLE
  #T_AMOUNT
  #E_DESCR
  #T_DESCR
  #T_CATALOG
  #CB_CATALOG
  #B_SAVE
EndEnumeration


Procedure OpenhWnd(x = 0, y = 0, width = 490, height = 340)
  OpenWindow(#hWnd, x, y, width, height, "", #PB_Window_SystemMenu | #PB_Window_SizeGadget | #PB_Window_TitleBar | #PB_Window_ScreenCentered)
  DateGadget(#D_DATE, 20, 40, 140, 40, "")
  StringGadget(#S_TITLE, 170, 40, 300, 40, "")
  StringGadget(#S_AMOUNT, 220, 270, 80, 40, "")
  TextGadget(#T_DATE, 20, 20, 100, 20, "Datum")
  TextGadget(#T_TITLE, 170, 20, 100, 20, "Titel")
  TextGadget(#T_AMOUNT, 220, 250, 80, 20, "Betrag €")
  EditorGadget(#E_DESCR, 20, 120, 450, 110)
  TextGadget(#T_DESCR, 20, 100, 100, 20, "Beschreibung")
  TextGadget(#T_CATALOG, 20, 250, 100, 20, "Kategorie")
  ComboBoxGadget(#CB_CATALOG, 20, 270, 170, 40, #PB_ComboBox_Editable)
  ButtonGadget(#B_SAVE, 320, 250, 150, 60, "Speichern")
EndProcedure

OpenhWnd ()

AddGadgetItem (#CB_CATALOG, -1, "Lebensmittel")
AddGadgetItem (#CB_CATALOG, -1, "Technik")
AddGadgetItem (#CB_CATALOG, -1, "Fahrzeug")
AddGadgetItem (#CB_CATALOG, -1, "Versicherung")
AddGadgetItem (#CB_CATALOG, -1, "Miete")
falsam
 
Posts: 209
Joined: Mon May 05, 2014 9:49 pm
Location: France

Re: Problem with Safari on iPhone

by falsam Thu Oct 12, 2017 2:42 pm

Strange I don't have this problem if I compile. On the other hand, there is a problem actually from your link.


Test your code : http://falsam.com/sbtest/amout.html

Version of SpiderBasic and OS?
➽ Windows 10 - JDK 1.8 - SB 2.20 - Android 5.5
Mood ☀️
http://falsam.com

Sorry for my poor english
Dirk Geppert
 
Posts: 5
Joined: Fri Sep 22, 2017 7:02 am

Re: Problem with Safari on iPhone

by Dirk Geppert Thu Oct 12, 2017 3:25 pm

Hi falsam, thanks for testing. I have the same problem on your side.
I am using SpideBasic 2.20 B1 on Windows 10 and iPhone Safari on iOS 11.0.3.

It looks like Safari is zooming in too far into the gadget. Maybe a ViewPort specification is missing in index. html?

Best regards
Dirk
Dirk Geppert
 
Posts: 5
Joined: Fri Sep 22, 2017 7:02 am

Re: Problem with Safari on iPhone

by Dirk Geppert Fri Oct 13, 2017 10:41 am

I ran some more tests. It works better with mobile browsers if the viewport is defined in the head area.
For example:

Code: Select all
<meta name="viewport" content="user-scalable=no, width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1">


@Fred: What's your opinion? Could you integrate that? It would also be good if it were configurable...

Kind regards

Dirk
Peter
 
Posts: 377
Joined: Mon Feb 24, 2014 10:17 pm

Re: Problem with Safari on iPhone

by Peter Fri Oct 13, 2017 11:01 am

Hello Dirk,

Dirk Geppert wrote:It works better with mobile browsers if the viewport is defined in the head area.

until there is a better solution available you can use this one:

Code: Select all
! $('head').append('<meta name="viewport" content="user-scalable=no, width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1">');


Greetings ... Peter
Dirk Geppert
 
Posts: 5
Joined: Fri Sep 22, 2017 7:02 am

Re: Problem with Safari on iPhone

by Dirk Geppert Thu Oct 19, 2017 3:44 pm

Hello Peter, thank you for the tip. Entries are now possible, but very difficult.
Especially the combobox can only be operated after several attempts.
Unfortunately, Spiderbasic doesn't seem to be suitable for mobile bowser.
Return to Coding Questions

Who is online

Users browsing this forum: SparrowhawkMMU and 3 guests