亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

pjblog發(fā)表評(píng)論用的ajaxJS.js

 更新時(shí)間:2007年04月25日 00:00:00   作者:  

document.write('<DIV id="loadingg"  style="HEIGHT:65px; WIDTH: 200px;POSITION: absolute; Z-INDEX:1000;border:3px;solid;text-align:center;sans-serif;color:#000000;background-color:#FFFFFF;opacity:.7;-moz-opacity:.7;filter: Alpha(Opacity=75, FinishOpacity=50, Style=1, StartX=0, StartY=1, FinishX=200, FinishY=100); display:none;"><br/><font color="#708090"><b>數(shù)據(jù)正在讀取中,請(qǐng)等候...</b></font><br/><img src="images/loading.gif"/></DIV>')
function showloading() 
{
var obj=document.getElementById("loadingg")
if (obj.style.display!="")
{
obj.style.left=((document.documentElement.clientWidth-parseFloat (obj.style.width))/2)+document.documentElement.scrollLeft+"px";
obj.style.top=((document.documentElement.clientHeight-parseFloat (obj.style.height))/2)+document.documentElement.scrollTop+"px";
obj.style.display="";
}else{obj.style.display="none";}
}


function $(id)
{
    return document.getElementById(id);    
}
function echo(obj,html)
{
    $(obj).innerHTML=html;
}
function fopen(obj)
{
    $(obj).style.display="";
}
function fclose(obj)
{
    $(obj).style.display="none";
}
function createxmlhttp()
{
    var xmlhttp=false;
    try    {
          xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
     } 
    catch (e) {
          try {
               xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
          } 
        catch (e) {
               xmlhttp = false;
         }
     }
    if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
          xmlhttp = new XMLHttpRequest();
                if (xmlhttp.overrideMimeType) {//設(shè)置MiME類別
            xmlhttp.overrideMimeType('text/xml');
        }
    }    

    return xmlhttp;    
}

function getdata(url,obj1,obj2)
{
        var xmlhttp=createxmlhttp();
        if(!xmlhttp)
        {
            alert("你的瀏覽器不支持XMLHTTP?。?);
            return;
        }
        showloading() 
        xmlhttp.onreadystatechange=requestdata;
        xmlhttp.open("GET",url,true);
        xmlhttp.send(null);
        function requestdata()
        {

                fopen(obj1);
                //echo(obj1,"正在加載數(shù)據(jù),請(qǐng)稍等......");
                //alert(xmlhttp.readyState)
                if(xmlhttp.readyState==4)
                {
                    if(xmlhttp.status==200)
                    {
                        if(obj1!=obj2){fclose(obj1);};
                        echo(obj2,xmlhttp.responseText);
                        showloading() 
                    }
                }

        }
}
function postdata(url,obj,data)
{       var rnd=Math.random()
        var xmlhttp=createxmlhttp();
        if(!xmlhttp)
        {
            alert("你的瀏覽器不支持XMLHTTP??!");
            return;
        }
        showloading() 
        xmlhttp.open("POST", url, true);
        xmlhttp.onreadystatechange=requestdata;
        xmlhttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
        xmlhttp.send(data);
        function requestdata()
        {
            fopen(obj);
            echo(obj,"正在提交數(shù)據(jù),請(qǐng)稍等......");
            if(xmlhttp.readyState==4)
            {
                if(xmlhttp.status==200)
                {
                    echo(obj,xmlhttp.responseText);
                    reget(rnd);
                    setTimeout("echo('showresult','')",2000);
                    echo('Message','')
                    showloading() 
                }
            }
        }
}
function lTrim(str)
{
  if (str.charAt(0) == " ")
  {
    //如果字串左邊第一個(gè)字符為空格
    str = str.slice(1);//將空格從字串中去掉
    //這一句也可改成 str = str.substring(1, str.length);
    str = lTrim(str);    //遞歸調(diào)用
  }
  return str;
}

//去掉字串右邊的空格
function rTrim(str)
{
  var iLength;

  iLength = str.length;
  if (str.charAt(iLength - 1) == " ")
  {
    //如果字串右邊第一個(gè)字符為空格
    str = str.slice(0, iLength - 1);//將空格從字串中去掉
    //這一句也可改成 str = str.substring(0, iLength - 1);
    str = rTrim(str);    //遞歸調(diào)用
  }
  return str;
}

//去掉字串兩邊的空格
function trim(str)
{
  return lTrim(rTrim(str));
}

function f(obj)
{
    return trim(eval("document.ajax_post."+obj+".value"));
    //return trim($(obj).value);
}

function SaveReply()
{
    if(f("username")=="")
    {
        alert("請(qǐng)?zhí)顚懹脩裘?);
        return false;
    }
    if(f("Message")=="")
    {
        alert("內(nèi)容不可為空");
        return false;
    }
    var validate,password,log_DisKey=0,log_DisURL=0,log_DisSM=0
    validate=""
    password=""
    if(document.ajax_post.log_DisKey.checked){
        log_DisKey=f("log_DisKey")
        }
    if(document.ajax_post.log_DisURL.checked){
        log_DisURL=f("log_DisURL")
        }
    if(document.ajax_post.log_DisSM.checked){
        log_DisSM=f("log_DisSM")
        }
    if((typeof eval(document.ajax_post.validate))!="undefined"){
        if(f("validate")=="")
        {
            alert("請(qǐng)?zhí)顚戲?yàn)證碼");
            return false;
        }else{
            validate=f("validate");
        }
    }    
    if((typeof eval(document.ajax_post.password))!="undefined"){
        password=f("password");
    }
    data="username="+escape(f("username"))+"&password="+escape(password)+"&validate="+escape(validate)+"&log_DisSM="+escape(log_DisSM)+"&log_DisURL="+escape(log_DisURL)+"&log_DisKey="+escape(log_DisKey)+"&Message="+escape(f("Message"))+"&logID="+escape(f("logID"))+"&action="+escape(f("action"));
    //alert(data);
    postdata("wbc_blogcomm.asp","showresult",data);
    return true;
}

相關(guān)文章

  • Ajax向后臺(tái)傳json格式的數(shù)據(jù)出現(xiàn)415錯(cuò)誤的原因分析及解決方法

    Ajax向后臺(tái)傳json格式的數(shù)據(jù)出現(xiàn)415錯(cuò)誤的原因分析及解決方法

    ajax往后臺(tái)傳json格式數(shù)據(jù)報(bào)415錯(cuò)誤,什么原因?qū)е碌哪?,該怎么解決呢?下面腳本之家小編給大家?guī)?lái)了Ajax向后臺(tái)傳json格式的數(shù)據(jù)出現(xiàn)415錯(cuò)誤的原因分析及解決方法感興趣的朋友一起看看吧
    2016-10-10
  • ajax中文亂碼問(wèn)題解決方案

    ajax中文亂碼問(wèn)題解決方案

    ajax中文亂碼問(wèn)題在中文中經(jīng)常會(huì)出現(xiàn)這種問(wèn)題,其實(shí)只要稍加注意就不會(huì)出現(xiàn)ajax中文亂碼這回事情了,接下來(lái)為大家詳細(xì)介紹下如何解決這類問(wèn)題
    2013-04-04
  • ajax傳送參數(shù)含有特殊字符的快速解決方法

    ajax傳送參數(shù)含有特殊字符的快速解決方法

    下面小編就為大家?guī)?lái)一篇ajax傳送參數(shù)含有特殊字符的快速解決方法。希望對(duì)大家有所幫助,一起跟隨小編過(guò)來(lái)看看吧
    2016-04-04
  • 初步了解JavaScript,Ajax,jQuery,并比較三者關(guān)系

    初步了解JavaScript,Ajax,jQuery,并比較三者關(guān)系

    這篇文章主要介紹了初步了解JavaScript,Ajax,jQuery,并比較三者關(guān)系的相關(guān)資料,需要的朋友可以參考下
    2015-10-10
  • js實(shí)現(xiàn)簡(jiǎn)單實(shí)用的AJAX完整實(shí)例

    js實(shí)現(xiàn)簡(jiǎn)單實(shí)用的AJAX完整實(shí)例

    這篇文章主要介紹了js實(shí)現(xiàn)簡(jiǎn)單實(shí)用的AJAX的方法,以完整實(shí)例形式分析了ajax無(wú)刷新調(diào)用的具體實(shí)現(xiàn)步驟與相關(guān)技巧,代碼備有詳盡的注釋便于理解,需要的朋友可以參考下
    2016-02-02
  • Ajax+php數(shù)據(jù)交互并且局部刷新頁(yè)面的實(shí)現(xiàn)詳解

    Ajax+php數(shù)據(jù)交互并且局部刷新頁(yè)面的實(shí)現(xiàn)詳解

    這篇文章主要給大家介紹了關(guān)于利用Ajax與php數(shù)據(jù)交互并且局部刷新頁(yè)面的實(shí)現(xiàn)方法,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面跟著小編一起來(lái)學(xué)習(xí)學(xué)習(xí)吧。
    2017-07-07
  • AJAX javascript的跨域訪問(wèn)執(zhí)行

    AJAX javascript的跨域訪問(wèn)執(zhí)行

    在網(wǎng)站調(diào)用加載評(píng)論等信息的時(shí)候遇到了不同域名間javascript不能執(zhí)行的問(wèn)題,一直都在加載中顯示不出來(lái),而換個(gè)網(wǎng)址訪問(wèn)的話就能正確顯示,一直沒去注意瀏覽器提示的錯(cuò)誤信息:
    2008-04-04
  • AJAX 驗(yàn)證框架13個(gè)

    AJAX 驗(yàn)證框架13個(gè)

    眾所周知,驗(yàn)證,最好是在客戶端盡量解決,以降低服務(wù)端資源開銷;在目前AJAX流行的今天,基于AJAX的驗(yàn)證更能夠?yàn)榭蛻舳蓑?yàn)證提供豐富的機(jī)制和美觀的交互效果。本文收集了13個(gè)比較通用的AJAX驗(yàn)證框架,與大家分享!
    2009-08-08
  • ajax 實(shí)現(xiàn)微信網(wǎng)頁(yè)授權(quán)登錄的方法

    ajax 實(shí)現(xiàn)微信網(wǎng)頁(yè)授權(quán)登錄的方法

    這篇文章主要介紹了ajax 實(shí)現(xiàn)微信網(wǎng)頁(yè)授權(quán)登錄的方法,小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2018-03-03
  • ajax加載頁(yè)面服務(wù)器返回 304 not modified

    ajax加載頁(yè)面服務(wù)器返回 304 not modified

    服務(wù)器都返回 304 not modified 說(shuō)明在服務(wù)器上,你這個(gè)xml文件沒有修改過(guò),或者要加載的頁(yè)面在本地沒有被修改,本地緩存造成了這個(gè)問(wèn)題
    2014-04-04

最新評(píng)論