为什么不runat =" client" [英] why not runat = "client"

查看:232
本文介绍了为什么不runat =" client"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道除了runat =server之外是否还有其他选项。

我知道runat =client在xfa中有效。但它在Asp.Net中是否有效?

对不起,我对这个领域很新。所以请帮助!!!

i want to know whether there are other options other than runat="server".
i know that runat="client" works in xfa. But does it work in Asp.Net?
Sorry i am completely new to this field. So please Help!!!

推荐答案

我同意,有点奇怪和神秘的符号。很明显, runat =client是否有效,但据我所知,它不是在ASP.NET中,或者它会是一个虚假的人。我无法解释这种不对称的符号,我怀疑这种解释是否合理。



在客户端运行的想法完全不同。 ASP.NET页面中编写的所有内容都是为响应HTTP请求而生成的,并在服务器的HTTP响应中发送给客户端。它可以包含任何MIME类型,任何内容,首先是HTML页面,其中包含常规客户端站点上执行的任何脚本。这基本上就是这样。其他一切只是方便编写这些内容和脚本的工具;例如,您可以在ASP.NET页面上注册客户端脚本等,但您可以简单地编写一些脚本代码,使用其他脚本和库,如jQuery等等。



-SA
Somewhat strange and cryptic notation, I agree. It would be clear if runat="client" worked, but, to best of my knowledge, it does not in ASP.NET, or it would be a bogus. I cannot explain such assymmetric notation and I doubt the explanation would be rational.

The idea of running at client is completely different. Everything written in ASP.NET page is generated in response to HTTP request and sent to client in HTTP response of the server. It can contain any MIME type, any content at all, and, first of all, HTML page with any scripts which are executed on client site as usual. That''s basically it. Everything else is just the tools for convenience of writing this contents and scripts; for example, you can register client-side script on ASP.NET page and the like, but you can simply write some script code, use other scripts and libraries like jQuery, and so on, so forth.

—SA


除了 runat =server,你没有任何其他选择

如果您查看以下链接,您将得到答案:

为什么ASP.NET仍然需要runat =server到处? [ ^ ]

Runat =''client''vs runat [ ^ ]

为什么asp.net webforms需要runat服务器属性 [ ^ ]

为什么runat服务器为asp.net part2 / [ ^ ]



Goodluck,

OI
No you dont have any other option than runat="server".
If you take a look at the following links you will have an answer:
Why does ASP.NET still require runat="server" everywhere?[^]
Runat=''client'' vs runat[^]
Why does asp.net webforms need the runat server attribute[^]
Why runat server for asp.net part2/[^]

Goodluck,
OI


这篇关于为什么不runat =" client"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆