1: function checkList(selection) { 2: if (selection.length == 0) { 3: window.alert(“You must make a selection from the list.”); 4: return false; 5: } 6: return true; 7: }
1: 6: In the new window Close the parent window in the window 7: window.opener.close()
66 Write content in the new window
1:
67 Load the page into the frame page
1: 5: Load the page in frame2 in frame1 6: parent.frame2.document.location = " 135b.html";
68 Sharing scripts between frame pages If there is a script in the html file in frame1
1: function doAlert() { 2: window.alert(“Frame 1 is loaded”); 3: }
Then the method can be called like this in frame2
1: 2: This is frame 2. 3:
69 Data public can be found on the frame page Define data items so that the data can be shared by pages in multiple frames
1: 4:
This way in frame1 Variables persistentVariable can be used in both frame2 and frame2 70 Framework code base According to some of the above ideas, we can use a hidden frame page as the code base of the entire frame set
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn