Chinaunix首页 | 论坛 | 博客
  • 博客访问: 108412
  • 博文数量: 24
  • 博客积分: 3020
  • 博客等级: 中校
  • 技术积分: 205
  • 用 户 组: 普通用户
  • 注册时间: 2008-05-23 16:24
文章分类
文章存档

2010年(1)

2008年(23)

我的朋友

分类:

2008-06-27 18:44:05

Version 0.5

In version 0.5, the loading message is done through the use of callback functions

After printJavascript:

<script type="text/javascript">
  xajax.callback.global.onRequest = function() {xajax.$('loading').style.display = 'block';}
  xajax.callback.global.beforeResponseProcessing = function() {xajax.$('loading').style.display='none';}
  </script>

In HTML somewhere

<div id="loading"><img src="images/loading.gif" alt="" /> Loading...</div>

in CSS somewhere

#loading {
    background: white;
    padding: 20px;
    border: 2px solid green;
    display: none; /* hidden */
    position: absolute;
    left: 50%;
    margin-left: -100px;
    top: 25%;
    width: 200px;
    /*height: 100px;*/
        /*margin-top: -50;*/
    font-weight: bold;
    font-size: large;
    }

是不是太简单了?!

 

阅读(1171) | 评论(1) | 转发(0) |
给主人留下些什么吧!~~

chinaunix网友2009-03-26 20:50:45

谢谢,看到的很多都是哪个之前的