SpiderBasic 3.10 is out !

Everything else that doesn't fall into one of the other categories.
Fred
Site Admin
Posts: 1820
Joined: Mon Feb 24, 2014 10:51 am

SpiderBasic 3.10 is out !

Post by Fred »

Hi there,

2025-07-30: We put a new final version online to fix 2 regressions, feel free to download it again if you already did it !

2025-07-28: Final is out, thanks for the feedback !

2025-06-30: Beta 2 is ready, with an updated doc for 3.10 and some new stuff:

Code: Select all

- Added: HeaderSection/EndHeaderSection to easily custozime the HTML </head> tag
- Added code signing for Windows installer and exe to avoid scary warning when installing
A new version of SpiderBasic is ready to test with some cool new features is available on your account !

Code: Select all

- Added: Android app creation support for Linux and MacOS !
- Added: New native notification library for mobile apps !
- Added: HTTPInfo() to get more info when using HTTPRequest()
- Added: HTTPTimeout() to control the timeout of HTTPRequest()
- Added: CopyMemory()
- Added: StringByteLength()
- Added: #PB_EventType_PageLoaded event support for WebGadget()
- Added: #PB_EventType_Resize support for ContainerGadget(), ScrollAreaGadget(), Canvas() and PanelGadget()
- Added: #PB_Image_Base64 flag for LoadImage() to load image encoded in Base64

- Updated: Cordova android 14 and Android SDK 35
- Updated: the Date library doc as it already supports date beyond 2038.
Here is an example for the new native notification lib:

Code: Select all

; You need to create an iOS or Android app to test it. It won't have any effect in the browser
;

; #PB_EventType_NotificationClicked
; #PB_EventType_NotificationTriggered

; #PB_Notification_Secret   ; Notification won't be shown on the lock screen
; #PB_Notification_Progress ; Progress-like notification (Android only)

; For ScheduleNotification():
;
; #PB_Notification_At
; #PB_Notification_InSecond
; #PB_Notification_InMinute
; #PB_Notification_InHour
; #PB_Notification_InDay
; #PB_Notification_InWeek
; #PB_Notification_InMonth
; #PB_Notification_InQuarter
; #PB_Notification_InYear
; #PB_Notification_EveryDate
; #PB_Notification_EveryMinute
; #PB_Notification_EveryHour
; #PB_Notification_EveryDay
; #PB_Notification_EveryWeek
; #PB_Notification_EveryMonth
; #PB_Notification_EveryYear

If ContainerMobile(#PB_Any, #PB_Mobile_Page, "margin:8px")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    ButtonMobile(0, "Click me")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    HtmlMobile("<br><br>")
    ButtonMobile(1, "Click me too !")
    HtmlMobile("<br><br>")
    ButtonMobile(2, "ProgressBar notif")
        HtmlMobile("<br><br>")
    ButtonMobile(3, "Cancel Notif 0")
    CloseMobileContainer()
  EndIf

  Procedure MobileEvents()
    Select EventMobile()
      Case 0
        CreateNotification(0, "Hello world !", "Which name do you want to use ?", 0)
        NotificationButton(0, 1, "OK")
        NotificationButton(0, 2, "Cancel")
        ScheduleNotification(0, #PB_Notification_At, Date()+10)
        
      Case 1
        CreateNotification(1, "2nd notification", "Hello"+Chr(10)+"Friends", 0)
        Debug "Schedule every minute"
        ScheduleNotification(1, #PB_Notification_EveryMinute) ; It's rounded to about 5 mins on Android
        
      Case 2
        CreateNotification(2, "2nd notification", "Copying files...", #PB_Notification_Progress)
        NotificationProgress(2, 50)
        SetNotificationText(2, "Copying 0 / 2...")
        ScheduleNotification(2)
        
      Case 3
        CancelNotification(0)      
    EndSelect
  EndProcedure

  
  Procedure TimerEvents()
    Static i
    Select EventTimer()
      Case 0
        i+1
        If IsNotification(2)
          SetNotificationText(2, "Copying "+i+" / 200...")
          NotificationProgress(2, i)
          If i > 20
            CancelNotification(2)
          EndIf
          
        EndIf
        
    EndSelect
  EndProcedure
  
  Procedure NotificationEvents()
    Select EventNotification()
      Case 0
        If EventType() = #PB_EventType_NotificationTriggered
          Debug "Triggered " + EventNotification()
        Else
          ButtonId = EventData()
          If ButtonId = 1
            Debug "OK pressed !"
          EndIf
          If ButtonId = 2
            Debug "Cancel pressed !"
          EndIf
        EndIf
    EndSelect
  EndProcedure
  
  AddTimer(0, 1000)
  
  BindEvent(#PB_Event_Mobile, @MobileEvents())
  BindEvent(#PB_Event_Timer, @TimerEvents())
  
  BindEvent(#PB_Event_Notification, @NotificationEvents())
About Android creation on Linux, be sure to run the 'install-cordova.sh' script from the spiderbasic home directory to install everything needed. If you think the script can be improved, don't hesitate to tell !

Have fun,

The Fantasie Software Team
User avatar
Caronte3D
Posts: 187
Joined: Sat Nov 23, 2019 5:21 pm
Location: Some Universe

Re: SpiderBasic 3.10 beta 1 is ready !

Post by Caronte3D »

We must update the Java version?
I get this error trying your native notification example (on Android):

Code: Select all

A problem occurred evaluating project ':app'.
> Failed to apply plugin 'com.android.internal.application'.
> Android Gradle plugin requires Java 17 to run. You are currently using Java 11.
EDIT:
Ok, with Java 17 compiles.
It's deprecated, but we can download it from:
https://jdk.java.net/archive/
User avatar
Peter
Posts: 1197
Joined: Mon Feb 24, 2014 10:17 pm
Location: 127.0.0.1:9080
Contact:

Re: SpiderBasic 3.10 beta 1 is ready !

Post by Peter »

Thanks for the new version! 👍

What are the chances that this feature request will also be included in the new version?

Add javascript and CSS scripts in the compilation options.
Fred
Site Admin
Posts: 1820
Joined: Mon Feb 24, 2014 10:51 am

Re: SpiderBasic 3.10 beta 1 is ready !

Post by Fred »

Caronte3D wrote: Mon Jun 02, 2025 9:24 am We must update the Java version?
I get this error trying your native notification example (on Android):

Code: Select all

A problem occurred evaluating project ':app'.
> Failed to apply plugin 'com.android.internal.application'.
> Android Gradle plugin requires Java 17 to run. You are currently using Java 11.
EDIT:
Ok, with Java 17 compiles.
It's deprecated, but we can download it from:
https://jdk.java.net/archive/
When updating cordova, all the toolchain is upgraded and it often requiers a newer Java. So yes, Java 17 is needed now instead of Java 11.
Fred
Site Admin
Posts: 1820
Joined: Mon Feb 24, 2014 10:51 am

Re: SpiderBasic 3.10 beta 1 is ready !

Post by Fred »

Peter wrote: Mon Jun 02, 2025 11:43 am Thanks for the new version! 👍

What are the chances that this feature request will also be included in the new version?

Add javascript and CSS scripts in the compilation options.
I will try to add it.
akee
Posts: 20
Joined: Fri Jun 27, 2014 7:20 pm

Re: SpiderBasic 3.10 beta 1 is ready !

Post by akee »

Thanks Fred...
falsam
Posts: 286
Joined: Mon May 05, 2014 9:49 pm
Location: France
Contact:

Re: SpiderBasic 3.10 beta 1 is ready !

Post by falsam »

Fred wrote: Mon Jun 02, 2025 1:52 pm
Peter wrote: Mon Jun 02, 2025 11:43 am Thanks for the new version! 👍

What are the chances that this feature request will also be included in the new version?

Add javascript and CSS scripts in the compilation options.
I will try to add it.
Thanks Fred 👍

➽ Windows 11 - jdk-11.0.2 - SB 3.00 - Android 15
https://falsam.com

Sorry for my poor english
munfraid
Posts: 135
Joined: Sat Mar 24, 2018 1:33 pm

Re: SpiderBasic 3.10 beta 1 is ready !

Post by munfraid »

Code: Select all

- Added: Android app creation support for Linux and MacOS !
:o finally freed from Windows! This is so great, thanks Fred!
User avatar
useful
Posts: 135
Joined: Tue Feb 25, 2014 1:15 pm

Re: SpiderBasic 3.10 beta 1 is ready !

Post by useful »

The help says: "To install SpiderBasic, please read the provided 'INSTALL' file. ", but there is no such file.
p. s. I'm writing about the linux version.
2B or not 2B = FF
Quin
Posts: 118
Joined: Wed Nov 08, 2023 4:38 pm

Re: SpiderBasic 3.10 beta 1 is ready !

Post by Quin »

Woot! Thanks Fred! This looks like fun!
Post Reply