Home >Web Front-end >HTML Tutorial >What are the disadvantages of iframes?

What are the disadvantages of iframes?

零下一度
零下一度Original
2017-06-24 10:56:193044browse

1. iframe will block the onload event of the main page;

2. The search engine retrieval program cannot interpret this kind of page, which is not conducive to SEO;

3. It will affect the parallel loading of the page .

Parallel loading: There is a limit to the number of loads under the same domain name at the same time:

Solution:

Use js to dynamically load page content into the src of the iframe. The sample code is as follows:
[html]
  1. <iframe id="fram">iframe>

  2. ## document.getelementbyid("fram")

    .src= "a2.html"

##

The above is the detailed content of What are the disadvantages of iframes?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn