Questions about C # code running in the browser when

The problem is introduced :

We vs2010 editor, etc., be written in a simple addition calculator. Will find a phenomenon, that is, if you are writing in the form of code, you can not Button button, you can do the sums side input side. But if we are inside a Web page, it can not do so, we often need to click the Enter will be implemented, the mouse away will be performed (set to true in the Properties AutoPostBack textchange time). Are they even open in some browsers. We have to add a button button to do the summation results page.

After pressing the button phenomenon :

We will find the page refreshes. This is because the data back to the results server (this time, we can find a server icon in the lower right corner of the page).

The reason for this is because the browser only know: HTML, CSS, JavaScript, C # code it does not recognize, it can not execute C # code.

But we want to execute C # code, which was part of the code to the server must then execute code on the server, after the implementation, before returning to the browser.

Why Microsoft C # do not do it again web, the same form of the function it ?

Because it will waste a lot of bandwidth, we take the example of the input side edge summation terms. Assuming that C # also did another web sides summed input side, so that is to continue to do the data from the browser to the server, and then spread from the server browser, so you need a lot of bandwidth. Avoid interaction between too much and servers. This is why we are stronger than in the web in the form of C # function.

Why do I need a server ?

Because the B / S inside, the server computing power is larger than the browser, which makes us need a lot of computing server is carried out.

Why is everyone in the brush when the e-course, speed is so slow ?

1, network bandwidth reasons

Access the server network bandwidth is not enough.

2, the number of receive window is not enough network

Ability of the server to accept is limited.

This is why Ali, Tencent's software with the reasons for not card.

 

Guess you like

Origin www.cnblogs.com/TomHard/p/12416399.html