Hello,
I have a script that opens a window and displays
the results of the search.
My page now has frames.
What I need to do now is open the results into
a frame. The main frame is named "ContentFrame" and
the frame I need the results to show in is named
"NavFrame"
Having trouble, where in the code do I make the
change to make the results show into the frame.
function FindPic() { // Search for a image.
TotalFound = 0;
SearchString = document.CutbookForm.SearchWord.value;
SearchString = SearchString.toLowerCase();
WriteResults = window.open("","resultwindow","height=600, width=275, toolbar=0, status=0, menubar=0, resizable=1, scrollbars=1");
WriteResults.document.open();
WriteResults.document.write('<style type=text/css>body{background:url(); font:13pt verdana}'
+ 'a{text-decoration:none}'
+ 'img{border:2px ridge #ffaaaa; height:70px; vertical-align:middle}'
+ '</style>'
+ 'You searched for: <i>' + SearchString + '</i>'
+ '<br>Category: <i>' + parent.document.CutbookForm.CategoryDropdown.options.value + '</i>'
+ '<p><b>Results:</b><br>');
for (loop=0; loop < ActiveVar ; loop++) {
Keyword = CutArray[loop].TxtVal;
Keyword = Keyword.toLowerCase();
URL = CutArray[loop].PicVal;
title = CutArray[loop].TitVal;
title = title.toUpperCase();//Changes letters in the results window.
SearchResult = Keyword.indexOf(SearchString);
SearchResult2 = title.indexOf(SearchString);
if (SearchResult != "-1" || SearchResult2 != "-1") {
WriteResults.document.write('<p><a href=javascript:ShowCutPic(' + loop + '); target="main"><img src=' + CutArray[loop].PicVal + '></a> ' + title);
TotalFound++;
}
}
WriteResults.document.write('<p><b>Returned ' + TotalFound + ' results.</b><p><a href="javascript:window.close();">close window</a>');
WriteResults.document.close();
}
I have a script that opens a window and displays
the results of the search.
My page now has frames.
What I need to do now is open the results into
a frame. The main frame is named "ContentFrame" and
the frame I need the results to show in is named
"NavFrame"
Having trouble, where in the code do I make the
change to make the results show into the frame.
function FindPic() { // Search for a image.
TotalFound = 0;
SearchString = document.CutbookForm.SearchWord.value;
SearchString = SearchString.toLowerCase();
WriteResults = window.open("","resultwindow","height=600, width=275, toolbar=0, status=0, menubar=0, resizable=1, scrollbars=1");
WriteResults.document.open();
WriteResults.document.write('<style type=text/css>body{background:url(); font:13pt verdana}'
+ 'a{text-decoration:none}'
+ 'img{border:2px ridge #ffaaaa; height:70px; vertical-align:middle}'
+ '</style>'
+ 'You searched for: <i>' + SearchString + '</i>'
+ '<br>Category: <i>' + parent.document.CutbookForm.CategoryDropdown.options.value + '</i>'
+ '<p><b>Results:</b><br>');
for (loop=0; loop < ActiveVar ; loop++) {
Keyword = CutArray[loop].TxtVal;
Keyword = Keyword.toLowerCase();
URL = CutArray[loop].PicVal;
title = CutArray[loop].TitVal;
title = title.toUpperCase();//Changes letters in the results window.
SearchResult = Keyword.indexOf(SearchString);
SearchResult2 = title.indexOf(SearchString);
if (SearchResult != "-1" || SearchResult2 != "-1") {
WriteResults.document.write('<p><a href=javascript:ShowCutPic(' + loop + '); target="main"><img src=' + CutArray[loop].PicVal + '></a> ' + title);
TotalFound++;
}
}
WriteResults.document.write('<p><b>Returned ' + TotalFound + ' results.</b><p><a href="javascript:window.close();">close window</a>');
WriteResults.document.close();
}