how can i redirect to another page ?

Just starting out? Need help? Post your questions and find answers here.
skinkairewalker
Posts: 120
Joined: Tue Jun 14, 2016 7:17 pm

how can i redirect to another page ?

Post by skinkairewalker »

hi everyone !
how can i redirect to another page in another server ?

example >
this is my page > mywebsite.com/index.html
so when i click in some button go to another page like google.com ?
falsam
Posts: 280
Joined: Mon May 05, 2014 9:49 pm
Location: France
Contact:

Re: how can i redirect to another page ?

Post by falsam »

An example with the window.open () function.

Code: Select all

Declare RunProgram()

OpenWindow(0, 0, 0, 0, 0, "", #PB_Window_Background)
HyperLinkGadget(0, 10, 10, 100, 22, "http://google.com", RGB(46, 139, 87))

BindGadgetEvent(0, @RunProgram())

Procedure RunProgram()
  Protected link.s = GetGadgetText(EventGadget())
  ! window.open(v_link, "_self");
EndProcedure

➽ Windows 11 - JDK 1.8 - SB 2.40 - Android 13
http://falsam.com

Sorry for my poor english
skinkairewalker
Posts: 120
Joined: Tue Jun 14, 2016 7:17 pm

Re: how can i redirect to another page ?

Post by skinkairewalker »

Thanks you very much Falsam ^^
CONVERT
Posts: 7
Joined: Thu Aug 24, 2017 7:43 am

Re: how can i redirect to another page ?

Post by CONVERT »

Thank you so much, Falsam!

It works. I use "_blank" instead of "_self" to open in another tab.
SpiderBasic 2.10 x86 Full version, Windows 10 home 32.
Post Reply