Results 1 to 3 of 3

Thread: running a script in a parent window

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Apr 1999
    Location
    Prague, Czech Republic
    Posts
    350

    running a script in a parent window

    Hi,
    I have a frameset, with common scripts on the frameset page and I would like to call these functions from within the individual frame pages. Is that possible?

    Thanks,
    John

  2. #2
    Frenzied Member dj4uk's Avatar
    Join Date
    Aug 2002
    Location
    Birmingham, UK Lobotomies: 3
    Posts
    1,131
    You need to have the functions physically within each of the pages you can't reference them using the DOM.

    However if you put all the functions into one .js file and then include it on every page the functions are needed with:

    <script language="JavaScript" type="text/javascript" src="filename.js"></script>

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Apr 1999
    Location
    Prague, Czech Republic
    Posts
    350
    OK, this would be fine if the script I'm trying to 'make public' is to do some changes on individual pages, but what I need is, to call function in another window/frame to process in that window.

    I was, for example, thinking of using parent.document.scripts collection, but I didn't find any type of 'execute' method.

    Oh yes and the situation why I am asking is to resize main frame, if the user closes some panel frame.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width