GSAnet Banner Swap





to tricks page

A question of FRAMEs... two questions, actually.

FRAMES are extremely popular and so chances are you will want to use them. Well, chances are you already use them. This short guide will list some problems that occur most frequently when frames are used.

Problem N1: Space between frames.
When you use frames, sometimes you want frames to join back to back to each other, without any space between the frames. This makes your FRAMESET look like a normal page. The biggest problem is that Internet Explorer and Navigator use different attributes to achieve this effect. Also Internet Explorer attribute is not widely recognised.

But, cutting to the chase, here are the attributes you have to use to make sure there is no space between the frames:

<FRAMESET BORDER=0 FRAMEBORDER="no" FRAMESPACING="0"> <TR><TD>

Explanations:

Attributes FRAMEBORDER and BORDER make Netscape Navigator display no border and so frames are "glued" to each other. FRAMESPACING attribute is used to make Internet Explorer display no 5-pixel wide space between the frames. This attribute is needed for Internet Explorer only, so don't forget to include it.

Problem N2: Scrolling
This is also not a widely-recognised problem. A <FRAME> attribute SCROLLING can have one of these three values: "yes", "no" and "auto". If it is set to "no", no scroll bars will be displayed, even if the page does not fit the screen. The "yes" value will always display both scrolling bars.

"Auto" will automatically add scrollbars as needed. E.g. if your frame does not fit horizontally, a horizontal bar will be displayed for this frame, if your frame does not fit vertically, vertical scrollbars will be displayed. Both Netscape Navigator and Internet Explorer correctly display the needed scrollbars. If document fits the frame, no scrollbars will be displayed. You cannot control scrollbars separately, e.g. you cannot switch horizontal scrollbar on or off.

You might run into problems with scrollbars if your <IMG> ALT attribute is too long. I've seen it more than once: if user's connection is bad and "auto-load images" option is switched off, the browser will display ALT captions. These ALT captions are rarely tested and might take much more space than the original images (especially when images are menu options). If a document containing a menu cannot fit a frame any more, and the SCROLLING is set to "auto", user will be presented with a menu frame plus two ugly scrollbars.

The cure is simple, switch off the "auto-load images" option and test the ALT captions. In any case, if you want to make sure the page cannot be scrolled, just use SCROLLING="no". Also don't forget to include NORESIZE, so that the frame cannot be resized.


©1997 repfect Drug design studio. All Rights Reserved.