PDA

View Full Version : Need some help and advice....


muschino
03-12-2006, 03:10 PM
Hi everyone,

I am in desperate need of some help and advice. My current website uses alot of iframes. The reason i have them on there is because i wanted to display new data when someone clicks on a button, without having to reload the page (as mine contains alot of images, it slows it down). See the site www.hairandbeautypages.com

Is there an alternative to iframes? I still want it to have the same principal, but not using iframes.

Also, is it possible for an iframe to be resized, acording to the size of the page it displays (meaning, instead of scrollbars apearing, it just makes itself bigger accordingly)


If not, what can i use? I am in desperate need, as the new site is about to be launched, and i NEED to either replace them with something elese, of make them change size acordingly.:eek:

aluminumpork
03-12-2006, 05:37 PM
Well, you can use a DIV with overflow set to auto. But it all depends on how you are pulling your data. I used to use divs and just pull the data in with Javascript. But if you are using a seperate pages to display the data, then an IFRAME is your best bet. I started using IFRAME because of the way Firefox handles div sizing differently than IE, and it's really frustrating.

So instead I use an IFRAME like:


<iframe frameborder="0" src="page.php" height="100%" width="100%">Your browser must support IFRAME</iframe>


That should resize accordingly.

muschino
03-12-2006, 08:07 PM
i mean i want it to resize acordingly to what it displays

aluminumpork
03-12-2006, 09:10 PM
Ahh... well then, I guess you could try using a div to do it then, although explaining how to do that is well beyond the scope of this reply box, and is very specific to what you are doing.

I suggest you take a look at some simple AJAX tutorials to get a grip on dynamically loading content into a div.

Of course if anyone else has any ideas, help me out :-D