Re: iframe refresh

[email protected] Wed, 23 Apr 2014 19:05:35 -0700 (PDT)
Newsgroups gmane.comp.mozilla.devel.xpfe
Message-ID <[email protected]>
On Wednesday, April 23, 2014 4:04:31 PM UTC-6, [email protected] wrote:
> On Thursday, April 10, 2014 3:25:42 PM UTC-7, [email protected] wrote:
> 
> > On Thursday, April 10, 2014 10:48:12 AM UTC-6, [email protected] 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...