Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
newone
Posts: 43
Registered: ‎02-05-2010
My Device: 8900

iframe contentWindow problem

Hello everyone,

 

my problem is that the function "document.getElementById('ifr').contentWindow.location.href "

did not function on the blackberry. I want to get the url of the website that is opened in the iframe. But I get nothing.

 

Hope someone has an idea.

 

thanx

newone

Regular Contributor
Saeger
Posts: 83
Registered: ‎04-29-2011
My Device: 9300 Curve

Re: iframe contentWindow problem

[ Edited ]

Hello guys, i know that the topic is a little old.. but i'm getting this error too...

BlackBerry OS5 - Curve 9300

i'm using the code:

return views[i-1].firstChild.contentWindow;

the firstChild is defined (and it's a iframe) but when i call the contentWindow of the iframe, it did not function...

Anyone has an idea?

 

edit: the url of the iframe it's localhost too (just another .html).

Márcio Saeger - Software Engineer, Softwell Solutions
Contributor
mikebevz
Posts: 17
Registered: ‎04-19-2012
My Device: Torch

Re: iframe contentWindow problem

It seems people keep getting same issues all over again. 

 

have you found a solution to this problem?

Developer
kamal_nigam
Posts: 434
Registered: ‎07-23-2012
My Device: Blackberry 10

Re: iframe contentWindow problem

i know this thread for BB Java Smarphone but i am getting same issue in BB10 device.

 

some one say we can ingnore this by enabling the web security. but  i fell we can't enable this on production code.

 

 

any help

 

 

Thanks
-------------------------------------------------------------------------------------
Press the Accept as solution Button when u got the Solution
Press Kudo to say thank to developer.
-------------------------------------------------------------------------------------.