Ok I think it worked the reason I want to store in the index from the iframe's iframe is to retrieve it in a popup window.
So here's what I have so far:
Code:
function createOrder(){
clickable=document.forms[0].check
txt=""
for (i=0;i<clickable.length;++ i){
if (clickable[i].checked){
txt=txt + clickable[i].value + " "
}
}
document.getElementById("order").value="You ordered: " + txt
}
function storeValue(what) {
var oreilly = new Array(); //to hold the answer from the user
oreilly[0] = parent.parent.document.getElementById("gal1").value;/*parent.parent.document.getElementById("gal1").value;*/ //copies the user buyer to index.html hidden field
oreilly[1] = parent.parent.document.getElementById("gal2").value; //copies the user buyer to index.html hidden field
oreilly[2] = parent.parent.document.getElementById("gal3").value; //copies the user buyer to index.html hidden field
oreilly[3] = parent.parent.document.getElementById("gal4").value; //copies the user buyer to index.html hidden field
oreilly[4] = parent.parent.document.getElementById("gal5").value; //copies the user buyer to index.html hidden field
if(what.checked = true) {
for(var i=0; i<oreilly.length; i++){
oreilly[i].value = what.value;
}
}
}
function openpopup(){
var oreilly = new Array(); //to hold the answer from the user
oreilly[0] = parent.parent.document.getElementById("gal1").value;/*parent.parent.document.getElementById("gal1").value;*/ //copies the user buyer to index.html hidden field
oreilly[1] = parent.parent.document.getElementById("gal2").value; //copies the user buyer to index.html hidden field
oreilly[2] = parent.parent.document.getElementById("gal3").value; //copies the user buyer to index.html hidden field
oreilly[3] = parent.parent.document.getElementById("gal4").value; //copies the user buyer to index.html hidden field
oreilly[4] = parent.parent.document.getElementById("gal5").value; //copies the user buyer to index.html hidden field
var newwindow1 = window.open("../orderform.html", "polar_bear", "width=450, height=420");
var tmp = newwindow1.document;
for(var i=0; i<oreilly.length; i++){
tmp.write(oreilly[i]);
}
}
createorder(); is used in the button as an onclick an is to test the checkboxes in the same page.
storeValue(what) is what you mentioned above
curtis it's storing to the index page (parent.parent.).
I have a popup page in the same directory of the index and I want to write in the popup whatever is stored in the hidden fields.