Howdy!
sharmaprateek wrote:
> Hello Community,
>
> I am able to access a global function in the child iFrame using the
> following syntax
>
> yourQxIframeInstance.getContentWindow().yourGlobalFunctionInTheIframeDocument()
>
> but now I also want to know what value does the function being called is
> returning.. at the moment the above mentioned calling method does not catch
> the value being returned..
>
> Consider the following scenario..
>
> I have an iframe instance in a simple document.
>
>
>
>
> // -- Parent window
>
> w1 = QxIframe("abc.html");
>
> var returnedResult = w1.getContentWindow().someFunction();
>
> alert returnedResult;
>
>
>
>
> /// --- w1 iframe has the following function ---
>
> function someFunction()
> {
> if (someCondition)
> {
> return true;
> }
> else
> {
> return false;
> }
> }
var yourGlobalIframeVariable = null;
function someHelperFunction()
{
yourGlobalIframeVariable = someFunction();
}
If both your document and your iframe document have the same domain
(security policies!), then you can access the value by:
yourQxIframeInstance.getContentWindow().yourGlobalFunctionInTheIframeDocument().yourGlobalIframeVariable;
Bye,
Andreas
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel