您的位置:首页 > Web前端 > JavaScript

设为首页的JS代码

2012-10-12 09:39 134 查看
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>设为首页的JS代码</title>
</head>
<body>
<p>方法一:<span onclick="var strHref=window.location.href;this.style.behavior='url(#default#homepage)';this.setHomePage('http://www.csdn.net');"  style="CURSOR: hand">点此设为首页</a></span></p>
<p><br>
方法二:<a title="设为首页" onclick="this.style.behavior='url(#default#homepage)';this.setHomePage('http://www.csdn.net');" href="javascript:;">设为首页</a>
</p>
</body>
</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: