Two source for one iframe - Forum

Forum Navigation
You need to log in to create posts and topics.

Two source for one iframe

Is it possible we use two sources for one iframe?

I need to use two sources for an iframe such that one source be offline and another source be online.

How should I do that?

I don't understand you very well.
If you mean two sources at the same time, it's not possible.
If you mean one now and another later, just use a variable as the source and change it's value to different URL's whenever needed.

I meant like this:

If [InternetAccess] = "TRUE"
SetVar [iFrameSource] "https://drv.tw/~asmatqatea@gmail.com/gd/MyAPP/index.html"
Else
SetVar [iFrameSource] "Main.html"
EndIf

In above I have just problem at "If conditional".

How I set a conditional like above?

 

asmat has reacted to this post.
asmat

Well @asmat, first we need to know if the URL is accesible or not (no Internet connection or server down).
As I think this is important I have done a small plugin to help with this task. If it works I will add it to the VisualNEO Web core commands. There is also a sample app attached.
It checks a URL and calls a subroutine if it's accessible and another one if it's not.
Please let me know if it works for you.

Uploaded files:
  • You need to login to have access to uploads.
asmat and javadrajabihakami have reacted to this post.
asmatjavadrajabihakami

Yeah, it works great.

Thank you so much...