且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

是什么使得语言成为客户端还是服务器端

更新时间:2023-11-27 22:21:46

问题本身似乎没有多大意义:是什么使语言成为客户端还是服务器端?没什么,有一些历史原因.例如,如果一种语言是命令式( http://en.wikipedia.org/wiki/Imperative_programming [ ^ ]),则可以将其潜在地用于服务器端.

但是,对此有一个重要问题.为什么服务器端语言和技术这么多,但是Web客户端服务器端只有JavaScript/ECMAScript? (我不算VB,因为许多浏览器不支持该语言.)

答案是:这是明显的社会现象,它是对基本Web技术和HTTP协议的回应".这是发展技术圈的生态问题",请参见 http://en.wikipedia.org/wiki/Novel_ecosystem [ ^ ].

客户端站点的功能应该是通用的,并在所有平台上都受支持,但是内容本身(包括脚本代码)是从服务器加载的.不同的语言会严重破坏Web的简单兼容性原理:Web应用程序应可在几乎所有平台和浏览器上运行.即使存在多个不兼容问题,尤其是在渲染方面,也可以通过准确编写的Web应用程序与那些平台和主要的浏览器兼容.因此, 多种客户端脚本语言无法生存;并且由于某些历史原因,只有JavaScript得以幸存.排除要求(例如经常使用ActiveX插件等不兼容的东西)证明了规则的合理性.

服务器端属于单个公司,或者是Web托管的单个用户,该主机通常提供一定范围的服务器端技术. Web应用程序的用户完全看不到服务器端.由于这个事实,服务器端技术的选择取决于网站的所有者 ,并且服务器端语言和技术蓬勃发展.

—SA


答案就在您自己的问题上,在客户端计算机上执行或运行的代码称为客户端(不执行不需要任何服务器来执行),并且在服务器端执行的代码(例如 IIS,Apache 等)称为服务器端.

希望对您有所帮助:)

有关更多查询的评论,请点击此处!


您可以获取一些信息 ^ ].这有一个不错的视频.

如果您正在查看脚本,请 Client-side_scripting [服务器辅助脚本 [ ^ ].

Respected Sir/Mam,

I would like to know by what pattern we call any language server-side or client side

Client side like:- HTML,javascript etc.

Server side loke:- ASP,PHP,Java etc.

What makes the above language to be called as server side or client side

Thanks in advance

A question itself does not seem to make much sense: what makes a language to be a client side or server side? Nothing, some historical reasons. If a language is, for example, imperative (http://en.wikipedia.org/wiki/Imperative_programming[^]), it could be potentially used on server side.

However, there is one important question about that. Why there are so many server-side languages and technologies, but Web client server-side is only JavaScript/ECMAScript? (I don''t count VB as this language is not supported by many browsers.)

The answer is: this is apparent social phenomena which emerged "in response" to basic Web technology and HTTP protocol. This is a matter of "ecology" of developing technosphere, see http://en.wikipedia.org/wiki/Novel_ecosystem[^].

Features of the client-site should be universal and supported on all platforms, but the content itself, including the script code, is loaded from the server. Different languages would strongly damage a simple compatibility principle of the Web: a Web application should work on nearly all platforms and browsers. And even though there are multiple incompatibilities, especially in rendering, accurately written Web applications are compatible with those platforms and major browsers. Due to this fact, multiple client-side scripting languages cannot survive; and by some historical reasons, only JavaScript survived. Exclusions like requirements to use incompatible things like ActiveX plug-ins, as it often happens, justify the rule.

Server-side belongs to a single company, or a single user of a Web hosting which usually provides some range of server-side technologies. The server-side remains completely invisible to the users of a Web application. Due to this fact, the selection of a server-side technology depends on an owner of a Web site, and the server-side languages and technologies flourished.

—SA


The answer is in your question itself, the code which executes or run at client machine is called a client side(which do not require any server for execution), and the code which executes at server(such as IIS, Apache etc.) end are called server side.

hope it helps :)

for further queries comment here!!


You can get some information here[^]. This has a good video to go through.

If you are looking at scripting, Client-side_scripting[^] and server side scripting[^].