Search code examples
javascriptajaxhtmliframeframeset

What is the downside of putting your entire website inside an iframe of the main landing page?


I have a facebook like chat bar at the bottom of my website and I also have a few other javascriptand ajax related code that loads on page load, I have not yet fully ajaxified this website but have to put it into production the problem is that these scripts take too long each time the page refreshes, just to initialize. So I though of taking them out and putting the entire website inside an iframe or frameset and this code on the outside of the frame.

I remember back in the day in the SO community, people always told to stay away from framesets and also even iframes would get a lot of comments. Can somebody enlighten me? What should I do?

I am using alot of html5 features like webstorage and alot of css3 if that makes any diffrence. Thanks for any insight!


Solution

  • You mean what are the downsides?

    1. Too many requests
    2. Will take a long time for the whole page to load
    3. No Search Engine Optimization

    Go for the ajaxified website instead. Might take you some time and effort to get started but it will be worthwhile.