zoukankan      html  css  js  c++  java
  • FAQ about AJAXpart I

    Q:
    does AJAX use still use a request/response model?
    A:
    Actually, your pages are still making request and getting responses. you 'are using a different approach in how you make those requests and handle the response--now you use javascirpt to make the actual request, instead of just submitting  a web form.

    Q:
    why not just submit the form normally?what does using Ajax really do for us?
    A:
    The javascript code in an Ajax application sends your requess to be processed by the serer, but doesnot wait for an anser. even better, javascript can also work with the server's response, instead of reloading the entire page when the server is finished with your request.

    Q:
    So does the page ever get back a resposne?
    A:
    That's where the asynchronous part of Ajax comes in. when the serve sends back a response, javascript can update a page with new values, change an image, or even take the user to a whole new web page, And the user never has to wait around while all this is going in.

    Q:
    so should we use Ajax for all of my requests?
    A:
        There are still of times when you'll want to use traditional web programming. for instance, when a form is totally filled out, you can let the user click a submit button, and then send the entire form to your web server, without using Ajax.
        But ,you 'll use Ajax for most of your dynamic page processing, like changing images,updating fields,and responding to users, if you only need to update part of a page, then Ajax is the way to go.

    Q:
    what's the relation XML with Ajax?
    A:
    sometimes, your javasript will use XML to talk back and forth with server, But you don't always need to use XML for your reqeusts.

    Q:
        does use have to use a certain browser to use Ajax apps?
    A:
        No, as long as your uses have javascript enabled in their web browers, this code should work without any problems. so your ajax apps wil run just fine on FireFox,Mozilla, IE,Netscape, and Opera.
        
    Q:
        what if someone has javascript disabeld in their browser?
    A:
        Unfortunately, Ajax apps require javascript to run. so users who have javacript disabled are not going to be able to use your ajax Apps.

    Q:
        we got two ways to send our client data to server, POST and GET. maybe POST is better than  GET?
    A:
        Post is usually used when you are sending a serer lots of data.  but Get is not like this.    

    Q:
        what's DOM, and how the Dom with with a HTML Page?
    A:
        Dom is the abbriviated form for Document Object Model. web Server use the DOM to represent an HTML web page. our javascript can use the DOM to update values in  a page. DOM can manipulate all elements in the HMTL page. for examples: document.getElementbyId("username") such like that..:)





  • 相关阅读:
    转:Unity3D的四种坐标系
    在知乎回答的一个问题:C#初学者以后往WP开发走,还是往unity3d走?哪个更有前景呢
    Unity3d 引擎原理详细介绍、Unity3D引擎架构设计
    vs2010打开vs2012的sln文件
    Unity3d不支持vistual studio2012?用vs2012打开unity c#脚本进行编码的方法。
    C#学习笔记15:字符串、文件、目录的操作方法
    C#学习笔记14:面向对象继承的特点和里氏转换
    C#学习笔记13:静态方法、方法重载和ref、out参数
    C#学习笔记12:枚举、结构、数组基础学习
    C#学习笔记11:C#中的顺序结构、分支结构、循环结构
  • 原文地址:https://www.cnblogs.com/Winston/p/1150605.html
Copyright © 2011-2022 走看看