I suggest the following:
When opening the pop-up containing the frameset, pass the variables to each of the individual frames as you put their SRC.
Also, you can call a frame from JavaScript by using this code:
parent.FrameName.document
So, for passing a var, you would use:
parent.FrameName.document.location.href = 'new.php?var1=1&var2=2';
Hope this helps
fLIPIS