1

正確には、いくつかのフレームセットで構成されるページ全体にスクロールバーを追加する必要があります:

if (some condition) {       
   document.writeln('<FRAMESET ROWS="*,' + scratchpad_size +
                    '" FRAMEBORDER="0" FRAMESPACING="2" BORDER="0" onUnload="cancel_window()">');
} else {
   document.writeln('<FRAMESET FRAMESPACING=0 MARGINHEIGHT=0 MARGINWIDTH=0 ROWS="*,' 
       + scratch_size + '" onUnload="cancel_window()">');
}

document.writeln('<FRAMESET COLS="230,*" onLoad="func(...)">');
document.writeln('<FRAME style="border: 1px #8B939A solid;" SRC="empty.html" NAME=menu MARGINHEIGHT=0 MARGINWIDTH=0 FRAMEBORDER=NO SCROLLING="$SESSION.scrolling" title="links"');
document.writeln('<FRAME style="border: 1px #8B939A solid;" SRC="$CAisd/html/empty.html" NAME=page MARGINHEIGHT=0 MARGINWIDTH=0 FRAMEBORDER=NO SCROLLING="$SESSION.scrolling" title="Data">');
document.writeln('</FRAMESET>');
document.writeln('<FRAME style="border: 1px #8B939A solid;" SRC="$cgi?OP=DISPLAY_FORM+SID=$SESSION.SID+FID=1 SCROLLING="auto" MARGINHEIGHT=2 MARGINWIDTH=0 FRAMEBORDER=NO title="scratch">');
document.writeln('</FRAMESET>');

基本的に、2 つのフレームと他のフレームを含む別のフレームセットをカプセル化する 1 つのフレームセットがあるため、すべての部分にスクロールバーがあり、ページ全体にスクロールバーが必要です。その方法は?

4

2 に答える 2

0

For any given object, you may add a scrollbar by setting its overflow css property, through javascript or stylesheets, to "scroll".

This information, together with some elbow grease, should solve your problem.

For example, if you want a scrollbar on the side of the entire page you would use:

document.getElementsByTagName('html')[0].style.overflowY="scroll";
于 2012-10-17T08:04:16.803 に答える
0

You can't have a scrollbar for a frameset. The frameset is always exactly the size of the window (or the frame, if it is a frameset within a frameset).

If you want a set of frames that is larger than the window, you need to use a regular page with iframe elements.

于 2012-10-17T08:04:19.163 に答える