# Simple JavaScript Modification Question!

**URL:** <https://forum.kirupa.com/t/simple-javascript-modification-question/84825>\
**Category:** web dev\
**Created:** [March 30, 2005, 7:30pm UTC](https://forum.kirupa.com/t/simple-javascript-modification-question/84825 "2005-03-30T19:30:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lrhb](https://avatars.discourse-cdn.com/v4/letter/l/e47774/32.png) [@lrhb](https://forum.kirupa.com/u/lrhb)\
**Post date:** [March 30, 2005, 7:30pm UTC](https://forum.kirupa.com/t/simple-javascript-modification-question/84825/1 "2005-03-30T19:30:46Z")

</div>

Hi there! I’ve got this bit of script for resizing iframes:

```auto
function loadIframe(iframeName, url) {
  if ( window.frames[iframeName] ) {
    window.frames[iframeName].location = url;   
    return false;
  }
  else return true;
}

```

if I want to define the iFrameName variable manually instead of passing it, and my iframe name is, say, content, should it look something like this?:

```auto
window.frames.content.location = url;

```

Thanks in advance! I don’t know much about JavaScript but it looks smashingly similar to ActionScript… however you can never be sure…

- lrhb :hat:
