Accessing Other Stacks in Webpage

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
gpearson
Posts: 84
Joined: Wed Feb 03, 2010 12:55 pm

Accessing Other Stacks in Webpage

Post by gpearson » Tue Mar 23, 2010 3:17 pm

While I have been developing a weather application for one of my websites, I have a SubStack apart of the main stack that when a button has been clicked it will set the visiblility of this substack to true which displays a graphic of a weather cam image. This works fine on when I am developing the application, but when I save as standalone fror the web, when I click the button I do not see the other stack. Any resources that I can look at to make this work like I think it should.
---
Graham Pearson
Goshen, IN USA

We Are Closed Today is your single internet resource for Indiana Area School Closings, Visit http://www.weareclosedtoday.com

sturgis
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 1685
Joined: Sat Feb 28, 2009 11:49 pm

Re: Accessing Other Stacks in Webpage

Post by sturgis » Tue Mar 23, 2010 9:10 pm

One method you might try is an ajax method. Setup your weathercam stack as a separate revlet, set your button that "shows" it to
do "javascript call here" in browser.

I use the really simple library here... http://www.dynamicdrive.com/dynamicinde ... ontent.htm its small and works well enough for this sort of thing. It means planning things out pretty tightly, but this way you can load the revlet in question, if needed with "GET" parameters, and pop the revlet up on screen. To get rid of it, set the container that you loaded it to blank.

Another method similar to this would be to load all applicable revlets initially and use do "javascript here" in browser to hide and show the container the revlet is in.

If needed I can dig up an example where i've done this, at the moment am kinda in the middle of a move so only have access to my laptop.

There is another method where, if you don't mind it covering your current revlet, and they're teh same size I belive you can "go to stack "yoursubstack" in this window" or something of that nature, but can't recall the exact command and structure at the moment.

Post Reply