注册 登录
编程论坛 JavaScript论坛

请教一个JS代码的使用

发布于 2010-04-28 14:06, 499 次点击
程序代码:
<html>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="MSHTML 6.00.2600.0" name=GENERATOR></HEAD>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<SCRIPT language=JavaScript><!--
var boodschap = 'http://127.0.0.1';
function dgstatus()
{
window.status = boodschap;
timerID= setTimeout("dgstatus()", 80);
}
dgstatus();
var Flag=0
//-->
</SCRIPT>
<body oncontextmenu=self.event.returnValue=false onselectstart="return false">
<div onClick="Flag++;return true">
<script type="text/javascript">
  u_a_client="3566";
  u_a_width="760";
  u_a_height="90";
  u_a_zones="14760";
  u_a_type="0";
</script>
<script src="http://js. onClick="Flag++;return true">
<iframe scrolling="no" width="300" height="300" src="http://code.2bj.cc:8899/click.html?adid=258&uid=zjs" frameborder="0" marginheight=0 marginwidth=0 ></iframe></div>

<div onMouseOver="window.status='点击广告!';return true" onClick="if(Flag==2) return true;
else {alert('你好象没有点我们的广告或者没有点全,请点击上面所有广告,等广告全打开你就可以进入了!');
return false}">
<a href=http://127.0.0.1 target=_blank>点击广告</a></div>
以上是一点击广告才能进入的代码,现在不能计算
<script type="text/javascript">
  u_a_client="3566";
  u_a_width="760";
  u_a_height="90";
  u_a_zones="14760";
  u_a_type="0";
</script>
<script src="http://js.
和<iframe scrolling="no" width="300" height="300" src="http://code.2bj.cc:8899/click.html?adid=258&uid=zjs" frameborder="0" marginheight=0 marginwidth=0 ></iframe>
这两种广告代码是否点击,要怎样修改才能实现这两种广告代码格式能够正常使用
4 回复
#2
foktime2010-04-29 14:15
<script src="http://js. //div结束标签
<div onMouseOver="window.status='点击广告!';return true" onClick="if(Flag>=2) return true;

PS. 你这例子图片太劲爆 让我没心理准备- -   然后怀疑你是打广告的
#3
2010-04-29 16:24
回复 2楼 foktime
大哥俺不是打广告的,是这两种类型的广告格式
这个代码如果直接用<a href="#">图片或文字</a>
能用,换成实例上的两种代码格式就用不了
按你的改成if(Flag>=4)也无法实现

[ 本帖最后由 yhcsh 于 2010-4-29 16:32 编辑 ]
#4
foktime2010-04-29 16:59
你给那俩div加上style="background-color:Red"看看你想点击的区域都跑哪去了
 
#5
2010-04-29 21:23
回复 4楼 foktime
只有本站会员才能查看附件,请 登录

应该没错,我用站长统计这类代码能有效计算,就是示例上的两种广告代码计算不到
1