faqts : Computers : Programming : Languages : JavaScript

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

2 of 4 people (50%) answered Yes
Recently 2 of 4 people (50%) answered Yes

Entry

How do I make a group of variable arrays available to a group of htms called by a frameset?

Apr 7th, 2008 22:33
ha mo, Jean-Bernard Valentaten, Alvin Fisher,


If I understand this question right, you want to have a set of arrays 
that is visible through your whole frameset.
Well that should be quite easy, simply declare the arrays in the 
frameset-file:
<html>
<head>
  <script language="JavaScript">
  <!--
    var myArray = new Array();
  //-->
  </script>
  <frameset...>
  ...
  </frameset>
</head>
</html>
From the documents it is accessed through parent.myArray both for 
reading and writing:
  for(var i=0; i < parent.myArray.length; i++)
  {
    alert(myArray(i));
    myArray(i) = someValue;
  }
If you use nested framesets, remember to use one parent keyword per 
nesting level.
HTH,
Jean
http://www.businessian.com
http://www.computerstan.com
http://www.financestan.com
http://www.healthstan.com
http://www.internetstan.com
http://www.moneyenews.com
http://www.technologystan.com
http://www.zobab.com
http://www.healthinhealth.com