iframe可以写在<body>标签里,如<body><iframe src="xxx"  name="xxx" style="width:100%;height:500px;"/></body>    iframe标签要成对,不然后面的标签不起作用

frameset不可以写在<body>标签里,如:

<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<frameset rows="50%,25%,*">
<frame name="frameset_target" src="./HelloWorld.html" noresize="noresize"/>
<frame src="/hello.java"/>
<frame src="/hello.java"/>
</frameset>
</html>

-----------------------------------------------------------------------------------------------iframe

	<h5>iframe__frameset</h5>
<p><a href="V1.jpg" target="iframe_target">iframe</a></p>
<p><a href="V1.jpg" target="frameset_target">frameset</a></p>
<iframe src="/hello.java" name="iframe_target" style="width:100%;height:500px;"/>

-----------------------------------------------------------------------------------------------frameset

注:必须先将frameset所在页面打开,然后,再点击里面的超链接到frame里的标签,(frameset的子标签是frame,不是iframe)

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<frameset rows="50%,25%,*">
<frame name="frameset_target" src="./HelloWorld.html" noresize="noresize"/>
<frame src="/hello.java"/>
<frame src="/hello.java"/>
</frameset>
</html>

  

-----------------------------------------------------------------------------------------------top和parent

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<body>
<a href="a_main.html">主界面</a>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<frameset rows="20%,*">
<!--noresize属性规定用户无法调整框架的大小,默认是可以通过拖动框架之间的墙壁来改变框架大小-->
<frame src="a_top.html" noresize="noresize"/>
<frame src="a_bottom.html" name="bottom" noresize="noresize"/>
</frameset>
</html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<body>
this is top.html
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<frameset cols="20%,*">
<!--noresize属性规定用户无法调整框架的大小,默认是可以通过拖动框架之间的墙壁来改变框架大小-->
<frame src="a_left.html" noresize="noresize"/>
<frame src="a_right.html" name="bottom" noresize="noresize"/>
</frameset>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
<body>
this is left.html
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title></title>
</head>
<body>
this is right.html
<a href="a_target_test1.html" target="bottom">test1</a>
<a href="a_target_test1.html" target="_parent">_parent</a>
<a href="a_target_test1.html" target="_top">_top</a>
</body>
</html>

  

最新文章

  1. 手机版web相关meta配置
  2. python基础(三)序列
  3. C#高级知识点01---委托和事件
  4. 【python】为什么修改全局的dict变量不用global关键字
  5. ArcGIS API for JavaScript Beta初步试探(一)
  6. Xamarin.Android开发实践(六)
  7. RewriteRule参数
  8. iOS第三方地图-百度地图定位的封装
  9. Project Euler 89:Roman numerals 罗马数字
  10. JavaScript自定义方法实现trim()、Ltrim()、Rtrim()
  11. Android中通过访问本地相册或者相机设置用户头像
  12. ionic2 干货
  13. Android判读是否安装了某一款APP
  14. PHP header() http各种状态码大全查询
  15. Basic Concepts of Block Media Recovery
  16. JS之链式运动,及任意值运动框架,包括透明度的改变
  17. 【bfs】 poj 3984 maze 队列存储
  18. LATEX TEMPLATE (SPRINGER) (*.BST)
  19. Centos7下用FastDFS搭建图片服务器
  20. 在线xss练习平台

热门文章

  1. C# 通知机制 IObserver&lt;T&gt; 和 IObservable&lt;T&gt;
  2. Secret of Chocolate Poles (Aizu1378——dp)
  3. 终端打印SQL语句
  4. Python os.listdir() 方法
  5. AtCoder ABC 085C/D
  6. 【codeforces 510D】Fox And Jumping
  7. poj 1724 最短路+优先队列(两个约束条件)
  8. [bzoj2989]数列_KD-Tree_旋转坐标系
  9. HDU 3666
  10. Bitcask存储模型