预览模式: 普通 | 列表

右下角浮动广告JS代码

<a href=http://www.lossr.net id="ad" style="position:absolute;z-index:100;"><img src="200x130.gif" border="0"></a>


<script type="text/javascript">
 var floatid="ad"; //浮动元素的ID
</script>
<script type="text/javascript" src="ad.js"></script>


ad.js 的内容为

 var Class = {
   create: function() {
     return function() {
       this.initialize.apply(this, arguments);
     }
   }
 }
 
 Function.prototype.bind = function() {
   var __method = this, args = $A(arguments), object = args.shift();
   return function() {
     return __method.apply(object, args.concat($A(arguments)));
   }
 }
 
 var $A = Array.from = function(iterable) {
   if (!iterable) return [];
   if (iterable.toArray) {
     return iterable.toArray();
   } else {
     var results = [];
     for (var i = 0; i < iterable.length; i++)
       results.push(iterable[i]);
     return results;
   }
 }

 var Float = Class.create();
 Float.prototype = {
  initialize: function(elem, options) {
   this.toDo = options.toDo || function(){},
   this.bodyScrollTop = document.documentElement.scrollTop || document.body.scrollTop,
   this.bodyScrollLeft = document.documentElement.scrollLeft || document.body.scrollLeft,
   this.element = document.getElementById(elem);
   this.dely = options.dely || 500;
   this.top = options.top || 0;
   this.left = options.left || 0;
   
  },
  
  start:function(){
   if(!this.element){
    alert('please set an element first!');
    return false;
   }
   this.element.style.position = 'absolute';
   this.toDo();
   setInterval(this.toDo.bind(this),this.dely)
  }
 }
 


var f = new Float('ad',{dely:100,
 toDo:function(){
  var isIE = document.all && window.external;
  this.bodyScrollTop = document.documentElement.scrollTop || document.body.scrollTop;
  this.bodyScrollLeft = document.documentElement.scrollLeft || document.body.scrollLeft;
  if(isIE){
   this.docWidth = document.documentElement.clientWidth || document.body.clientWidth;
   this.docHeight = document.documentElement.clientHeight || document.body.clientHeight;
  }else{
   this.docWidth = (document.body.clientWidth > document.documentElement.clientWidth)?document.documentElement.clientWidth:document.body.clientWidth;
   this.docHeight = (document.body.clientHeight > document.documentElement.clientHeight)?document.documentElement.clientHeight:document.body.clientHeight;
  }

  this.element.style.top = (this.docHeight - parseInt(this.element.offsetHeight,10)) + parseInt(this.bodyScrollTop, 10)+ 'px';
  this.element.style.left = (this.docWidth - parseInt(this.element.offsetWidth,10)) + parseInt(this.bodyScrollLeft, 10) + 'px';
 }
});
f.start();


INTEL Core i7 920

Intel Core i7-965 Processor Extreme Edition拥有3.2GHz主频,8MB三级缓存,QPI频率6.4GT/s,45nm制造工艺,LGA 1366插槽。

帝国热门标签排行 TAG,收藏



免得以后要用的时候找不到,先在博客里给收藏了。以后自己要用也方便很多。

下载文件1200075731.zip (1.68 KB , 下载:37次)

下载文件1220509441.rar (1 KB , 下载:26次)



导入标签即可,调用格式为:[showtags]'数量','表名'[/showtags]
默认数量为:100
表名为:news

标签: 帝国

GD空间客户ID保存

该日志已被加密

日志 200 0 64

    昨天发现很多人都还在关注 200 0 64 IIS日志中的蜘蛛访问记录,而且网上找了下,都发现有很多乱七八糟的猜想,各种想法都有,有些甚至认为是被K 的前兆,个人感觉应该不是这样的。 200 0 0表示的肯定是 正常访问,正常抓取了,通过查看我的几个站的 IIS日志,最后个人觉得,最简单的意思是,200 0 0是正常访问抓取, 200 0 64 是 蜘蛛正常访问到,跳过页面,不抓取。 这个原因可能是他本来已经访问过你该页,或者说该页内容没有变化,他跳过,不做处理,或者他数据库中已经收录了该页,而不做进一步抓取,而跳过。个人感觉和K不K 的基本没有什么多大关系

明网空间倒下了?

    以前好像貌似他这个信誉和口碑还不错的,不过就这么一下子倒下了。诶,这个互联网的事情,谁也说不好。让谁倒,谁就能一下子倒。他倒下了,就苦了一大堆可怜的站长,站几天没开基本就死了。站长的权力不知道谁能来保护。。辛苦 辛苦、、、

CSS控制图片自适应宽带,自动适应宽度

fit-image{ 
  border  :0; 
  max-width:500px; 
}

500PX 当图片大于500PX时,自动缩小到 500PX,Firefox/Opera/IE7支持,IE6不支持


下面的是 方法

fit-image{ 
  border  :0; 
  max-width:500px; 
  width:   expression( 
   function(img){ 
    img.onload=function(){ 
     this.style.width=’’; 
     this.style.width=(this.width>500)?"500px":this.width+"px" 
    }; 
    return’120px’ //加载时显示宽度为120px 
   }(th

[阅读全文]

标签: CSS

给网页加上QQ即使对话

<a target=blank href=http://wpa.qq.com/msgrd?V=1&Uin=你的QQ号&Menu=yes> <img border="0" SRC=http://wpa.qq.com/pa?p=1:你的QQ号:1 alt="点击这里给我发消息"></a>


范例 点击这里给我发消息