asp.net – 什么是部分回发?

我是一个经验丰富的网页开发人员在几个不同的网络技术堆栈.我现在在.Net工作,我对部分回发变得好奇.

我明白Partial Postback的功能是什么,以及如何以编程方式使用它,但是我不喜欢使用我不明白的技术,那么Partial Postback如何实现.

我了解HTTP请求和异步请求,有关部分回发错误的事情是,它似乎是两者.

也许我只是错过了一些东西,但是在我看来,部分请求同时执行,首先触发异步POST请求,但是浏览器似乎知道,活动指示符开始旋转,这通常只发生在HTTP请求页面渲染.

任何人都可以看出微软如何在HTTP请求级别实施部分回发?

解决方法

How to write your own partial postback in ASP.NET 2.0

At the heart of the partial post back construction is the XMLHttpRequest,a DOM API. It can be used inside a web browser scripting language,such as JavaScript,to send an HTTP request directly to a web server without having to reload the entire page and handling the response from the server again within the scripting language. This data,in the form of XML,can then be used to manipulate the page elements on the client side.

When the button on the ASPX page has been clicked,a client side HTTP request is made using the XMLHttpRequest API. This request is handled by an HttpHandler on the web server. The HttpHandler receives the request,processes it,and sends back the response to the XMLHttp object on the ASPX page. The XMLHttp object in turn consumes the response and renders the appropriate UI changes without the browser having to do a full refresh of the page.

UpdatePanel不仅刷新它所包含的控件,还可以在处理完成后从服务器获取的ViewState值更新.

相关文章

### 创建一个gRPC服务项目(grpc服务端)和一个 webapi项目(...
一、SiganlR 使用的协议类型 1.websocket即时通讯协议 2.Ser...
.Net 6 WebApi 项目 在Linux系统上 打包成Docker镜像,发布为...
一、 PD简介PowerDesigner 是一个集所有现代建模技术于一身的...
一、存储过程 存储过程就像数据库中运行的方法(函数) 优点:...
一、Ueditor的下载 1、百度编辑器下载地址:http://ueditor....