·: Site description :·
Welcome!

NetBulge.com provides code, scripts, tips & tricks and general information about web development aimed to help webmasters and web designers.

Instead of packing all the info we can get into a huge database, our goal is to produce a high quality compilation of code snippets and articles. Web developers will find in these pages a fresh and savvy view of most of the issues concerning programming and designing for the web; as well as a good site to visit regularly for help and inspiration.

Enjoy!
Zones
Navigation
Search

Sessions

NetBulge.com RSS2 feed



About Hosting:

I use and recommend Hostgator for all my hosting needs. It is the only company I have tried (and I have tried plenty) that hasn't given me a headache and responds quickly and fairly to everything I ever need. I run 3 accounts that host over 20 sites with Hostgator and I am happy recommending it to all my family, friends and clients. If you are looking for a cheap yet solid host, IMO Hostgator is the way to go. I do get a comission if you register through the link, but even if you don't like me and don't want me to get a comission, go to Hostgator for your hosting needs and save yourself plenty of cash and headaches.


 Print version Send article via e-mail  

IFRAME behavior using DIV


web zone resourcesIFRAMEs are very useful for embedding content into a web page, particularly another URL. They are often misused for their box functionality and scrollbars. CSS has a property that allows for better control and a more reliable use: Overflow.


An IFRAME lets you embed a page into another one creating a box or frame within your page; like this:

<iframe height="250" width="250" src="http://www.google.com">
   Your browser can't display IFRAMEs
</iframe>

 

If you want to present content in a similar fashion, that is, within a box with scrollbars, you can use a block element (a DIV for this example) and style it with CSS Overflow:

<div style="width:250px; height:250px; overflow:scroll">
   Test content. This is a block element, in this case a DIV,
   styled to have specific width and height,
   and also features overflow control.
</div>

 

Overflow supports the following values:

visible
If there is content exceeding the box’s size, it will flow out of the box

Test content. This is a block element, in this case a DIV, styled to have specific width and height, and also features overflow control.

 

hidden
If there is content exceeding the box’s size, it will be hidden

Test content. This is a block element, in this case a DIV, styled to have specific width and height, and also features overflow control.

 

scroll
Force display of horizontal and vertical scrollbars

Test content. This is a block element, in this case a DIV, styled to have specific width and height, and also features overflow control.

 

auto
Show scrollbars if necessary (either horizontal, vertical or both)

Test content. This is a block element, in this case a DIV, styled to have specific width and height, and also features overflow control.

 




Author : Esopo, Read 34948 times, Comments: 1
Rating :  rating resourcesrating resourcesrating resourcesrating resourcesrating resourcesrating resourcesrating resourcesrating resourcesrating resourcesrating resources  |  Thursday, 9. June 2005

Add new comment/Comments
Your rating :   Poor ranking resourcesrating resourcesrating resourcesrating resourcesrating resources Excellent




css stylescss stylesDo you have something to say?
Then say it! NetBulge.com is devoted to web development. We are always looking for fresh and relevant ideas. If you are a web designer with a voice, this is the place to make it heard. Join us!

Featured *
Need I say anything? - The best browser out there, period. A well designed efficient interface is only the beginning here; web safety and a truck load of good extensions are the turning point. If you haven’t tried it yet, you are seriously missing out.

If you are a coder and were not aware of this site, you have been seriously missing out. At Hotscripts.com you will find a very extensive collection of all sorts of scripts that will ease the work load, serve as a starting point for a new script, or simply serve as an inspiration source for good code programming.
http://www.hotscripts.com/