iframe refresh

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

iframe refresh

tarima85
Is there a way to refresh the contents of an iframe? I tried document.getElementById("iframeid").setAttribute("src","website_url"); but it didn't work.
_______________________________________________
dev-tech-xul mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-tech-xul
Reply | Threaded
Open this post in threaded view
|

Re: iframe refresh

reverendlinux-2
On Thursday, April 10, 2014 10:48:12 AM UTC-6, [hidden email] wrote:
> Is there a way to refresh the contents of an iframe? I tried document.getElementById("iframeid").setAttribute("src","website_url"); but it didn't work.


Is "website_url" a variable or a string?  As shown in your example, it's a string and that won't work.

The following worked for me:

doRefresh(website_url) {
   document.getElementById("iframeid").setAttribute("src",website_url);
}
_______________________________________________
dev-tech-xul mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-tech-xul
Reply | Threaded
Open this post in threaded view
|

Re: iframe refresh

tarima85
On Thursday, April 10, 2014 3:25:42 PM UTC-7, [hidden email] wrote:

> On Thursday, April 10, 2014 10:48:12 AM UTC-6, [hidden email] wrote:
>
> > Is there a way to refresh the contents of an iframe? I tried document.getElementById("iframeid").setAttribute("src","website_url"); but it didn't work.
>
>
>
>
>
> Is "website_url" a variable or a string?  As shown in your example, it's a string and that won't work.
>
>
>
> The following worked for me:
>
>
>
> doRefresh(website_url) {
>
>    document.getElementById("iframeid").setAttribute("src",website_url);
>
> }

Yup, stupid mistake. Sorry!
_______________________________________________
dev-tech-xul mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-tech-xul
Reply | Threaded
Open this post in threaded view
|

Re: iframe refresh

reverendlinux-2
On Wednesday, April 23, 2014 4:04:31 PM UTC-6, [hidden email] wrote:

> On Thursday, April 10, 2014 3:25:42 PM UTC-7, [hidden email] wrote:
>
> > On Thursday, April 10, 2014 10:48:12 AM UTC-6, [hidden email] wrote:
>
> >
>
> > > Is there a way to refresh the contents of an iframe? I tried document.getElementById("iframeid").setAttribute("src","website_url"); but it didn't work.
>
> >
>
> >
>
> >
>
> >
>
> >
>
> > Is "website_url" a variable or a string?  As shown in your example, it's a string and that won't work.
>
> >
>
> >
>
> >
>
> > The following worked for me:
>
> >
>
> >
>
> >
>
> > doRefresh(website_url) {
>
> >
>
> >    document.getElementById("iframeid").setAttribute("src",website_url);
>
> >
>
> > }
>
>
>
> Yup, stupid mistake. Sorry!

If I had $1 for every time I've missed something like that over the years, I'd sure wouldn't be driving a Ford right now.  :-)

Glad I could help...
_______________________________________________
dev-tech-xul mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-tech-xul