That did the trick! I guess I misread the documentation on the child selector, though it makes sense now that you point it out. Thank you very much :)
On Nov 13, 12:55 pm, "Hector Virgen" <[EMAIL PROTECTED]> wrote: > It looks like the iframe is not an immediate descendant of the div with id > "win10". Remove the ">" from your selector and it should work: > $(win+' iframe').attr("src",url); > > -Hector > > On Thu, Nov 13, 2008 at 10:51 AM, CodingCyborg <[EMAIL PROTECTED]>wrote: > > > > > <div class="draggableWindow personalWin" id="win10"> > > <h1><span></span>Personal Settings</h1> > > <div class="content"> > > <iframe src="settings.php"></iframe> > > </div> > > </div> > > > And then elsewhere i have a link that onclick does link > > ("#win10","mailbox.php") > > The window has the focus changed so I know the code is passing through > > the function, but even if I take off the "if(url)" part it doesn't > > change the src... > > > On Nov 13, 9:26 am, ricardobeat <[EMAIL PROTECTED]> wrote: > > > That should work, can you show us some HTML? > > > > On Nov 13, 1:02 pm, CodingCyborg <[EMAIL PROTECTED]> wrote: > > > > > I currently have this function set up: > > > > > function link(win,url){ > > > > if(url){ > > > > $(win+' > iframe').attr("src",url); > > > > } > > > > setFocus(win); > > > > > } > > > > > And I don't get any errors in the console. > > > > win is a div that contains an iframe hence the child selector. > > > > I've tried a few different things but o no prevail... > > > > Help is appreciated :)