Better alternative to an iframe?

前端 未结 8 1610
臣服心动
臣服心动 2020-12-05 03:20

I have a page with an iframe to feature the contents of the clicked tab. There are 3 tabs and 1 iframe. The sources of the contents relating to each tab clicked are formatte

8条回答
  •  爱一瞬间的悲伤
    2020-12-05 03:30

    The only alternative to using IFRAMEs to load dynamic content (after the page has loaded) is using AJAX to update a container on your web page. It's pretty elegant and usually faster than loading a full page structure into an IFRAME.

    • Ajax with JQuery (use this and you will be loved on SO; the AJAX functions are great and simple)
    • Ajax with Prototype
    • Ajax with MooTools
    • Standalone Ajax with Matt Kruse's AJAX toolbox (Used to use this, using JQuery today because I needed a framework)
    • AJAX with Dojo (Said to be fast, but AJAX is not as straightforward)

提交回复
热议问题