发布于 2017-03-15 12:28:56 | 109 次阅读 | 评论: 0 | 来源: 网友投递

这里有新鲜出炉的Javascript教程,程序狗速度看过来!

JavaScript客户端脚本语言

Javascript 是一种由Netscape的LiveScript发展而来的原型化继承的基于对象的动态类型的区分大小写的客户端脚本语言,主要目的是为了解决服务器端语言,比如Perl,遗留的速度问题,为客户提供更流畅的浏览效果。


这篇文章主要介绍了js通过iframe加载外部网页的实现代码,需要的朋友可以参考下

今天从别的网站看到的,不需要跳转到别的页面直接本域名下调用外部网页。里面用js控制iframe的大小,确实不错。


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>phperz_www.phperz.com</title>
<meta name="keywords" content="phperz,phperz_www.phperz.com" />
<meta name="description" content="phperz相关信息,phperz_www.phperz.com" />
<link rel="shortcut icon" type="image/x-icon" href="./favicon.ico">
<link href="images/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="js/jquery.min.js"></script>
<script type="text/javascript"> 
window.onerror=function(){return true;} 
$(function() { 
headerH = 0;  var h = $(window).height();
  $("#huoduan_frame").height((h-headerH)+"px"); 
});
</script>
<!--[if IE 6]>
<script type="text/javascript" src="js/DDPNG.js"></script>
<script type="text/javascript">
DD_belatedPNG.fix('.png');
</script><![endif]-->
</head>
<body scroll="no" style="margin:0; padding:0; overflow-y:hidden ">
<iframe id="huoduan_frame" frameborder="0" scrolling="yes" name="main" src="http://www.phperz.com/index.htm" style=" height:500px; visibility: inherit; width: 100%; z-index: 1;overflow: visible;"></iframe>
<div style="display:none">
© <a href="http://so.phperz.com/">好搜网</a> <a href="http://so.phperz.com/" target="_blank">最好的搜索引擎</a> 以上搜索结果由<a href="http://so.phperz.com/" target="_blank">百度</a>驱动 </div>
</body></html>

phperz小编注: 里面使用了jquery。



最新网友评论  共有(0)条评论 发布评论 返回顶部

Copyright © 2007-2017 PHPERZ.COM All Rights Reserved   冀ICP备14009818号  版权声明  广告服务