[ANSWERED]: Iframe help

This is an archive of older posts. You can't add topics - rather, create a new topic in one of the forums above. You can still reply to topics in this forum though we encourage you to start a new topic in the forums above instead.
gbiski
Posts: 93
Joined: Wed Dec 19, 2012 2:17 pm

[ANSWERED]: Iframe help

Post by gbiski »

I have created an html with an iframe containing my graphs at thinkspeak.
I want this html to be embedded on one of my control pages. In this way to be able to see it via my web browser or indigo touch.
I tried but with no success.
Which is the technique to achieve it?

Thanks
gbiski
Posts: 93
Joined: Wed Dec 19, 2012 2:17 pm

Re: Iframe help

Post by gbiski »

Any help on this issue?
User avatar
jay (support)
Site Admin
Posts: 18351
Joined: Wed Mar 19, 2008 11:52 am
Location: Austin, Texas
Contact:

Re: Iframe help

Post by jay (support) »

Control pages cannot contain iframes - and even if they could Indigo Touch couldn't show them because it doesn't render control pages via html. An alternative would be to do it the other way around: put the control page into an iframe.
Jay (Indigo Support)
Twitter | Facebook | LinkedIn
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: Iframe help

Post by MarcoGT »

jay (support) wrote:An alternative would be to do it the other way around: put the control page into an iframe.
How can I do that?

Thanks
User avatar
DaveL17
Posts: 6845
Joined: Tue Aug 20, 2013 11:02 am
Location: Chicago, IL, USA
Contact:

Re: Iframe help

Post by DaveL17 »

MarcoGT wrote:How can I do that?
Take a look at this post which shows some example code that places Indigo control pages into HTML iFrames. It requires a little HTML coding on your part, but it's pretty straightforward once you get the hang of it.

Dave
I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: Iframe help

Post by MarcoGT »

Thanks,

so then in my CP as "Client Action" I have to select "Go to external URL"?
Or, how can I load that CP?

Thanks
Marco
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: Iframe help

Post by MarcoGT »

Now I have a test.html containing iframes with WUnderground charts + Thingspeak charts, it it just a test.
Now, I to use it inside Indigo?

Thanks
User avatar
DaveL17
Posts: 6845
Joined: Tue Aug 20, 2013 11:02 am
Location: Chicago, IL, USA
Contact:

Re: Iframe help

Post by DaveL17 »

MarcoGT wrote:Thanks,

so then in my CP as "Client Action" I have to select "Go to external URL"?
Or, how can I load that CP?

Thanks
Marco
That's my preferred approach.

Put a static image on the CP and then link to external URL. I also like to have something on the page with iFrames to send the user back to Indigo CP (in case the browser back button isn't obvious...)

Dave
I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: Iframe help

Post by MarcoGT »

Which address do you configure?
Something like file:///<path_to_file> or something like http://<ip_address>:<port>/<path>?

IP address is of course the IP address where Indigo Server is running, and what about port?
Shall I start a Web Server on the MacMini (running Indigo Server)?

Thanks
User avatar
DaveL17
Posts: 6845
Joined: Tue Aug 20, 2013 11:02 am
Location: Chicago, IL, USA
Contact:

Re: Iframe help

Post by DaveL17 »

I need to revise my prior statement. Now I'm not so sure that I ever did load an external URL from the Indigo server through a control page. I may have done it directly from a bookmark in the browser. Perhaps Matt or Jay could weigh in here on whether its possible to load a local HTML file through the IWS.

Dave
I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: Iframe help

Post by MarcoGT »

Ok, thanks
I will wait for an answer from M&J :)
User avatar
matt (support)
Site Admin
Posts: 21453
Joined: Mon Jan 27, 2003 1:17 pm
Location: Texas
Contact:

Re: Iframe help

Post by matt (support) »

I believe you will need to start Apache on your Mac to serve the file using an http:/// URL. The file:/// URL would only work if you accessed it from Safari on the Mac that hosted that file (likely your Indigo Mac).

That said, I think I have an easier way. The above approach is complicated since it requires Apache to run, and then you'll need to do router port forwarding/etc. to get access to that server when away from your house (reflectors only work for the Indigo web server, not Apache).

But if the file you want to server is straight HTML and not PHP/etc., then you can just drop it into this folder:

Code: Select all

/Library/Application Support/Perceptive Automation/Indigo 6/IndigoWebServer/static/
It will then be accessible from Indigo's web server directly. If you are using a reflector the format to access foo.html would be:

http://yourreflector.indigodomo.net/static/foo.html
Image
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: [ANSWERED]: Iframe help

Post by MarcoGT »

Thanks Matt, I will go for the easier way?
Is this the standard approach to have iframes in Indigo CP?

Thanks :)
User avatar
matt (support)
Site Admin
Posts: 21453
Joined: Mon Jan 27, 2003 1:17 pm
Location: Texas
Contact:

Re: [ANSWERED]: Iframe help

Post by matt (support) »

Control Pages themselves cannot have iframes, but you can embed a Control Page into an iframe of another HTML file (is that what you are doing?).
Image
MarcoGT
Posts: 1111
Joined: Thu Sep 11, 2014 1:06 pm
Location: Germany

Re: [ANSWERED]: Iframe help

Post by MarcoGT »

Yes, this is what I would like to do.
Post Reply

Return to “Archived Posts”