我的问题的更多细节:
HTML 和 JavaScript 被称为“客户端代码”。
代码隐藏文件中的 C# 和 VB 称为“服务器端代码”。
那么什么是 inline-asp 和 'runat=server' 代码块调用?
<!-- This is called "client-side" -->
<p>Hello World</p>
<script>alert("Hello World");</script>
...
// This is called "server-side"
public void Page_Load(object sender, EventArgs e)
{
Response.Write("Hello World");
}
...
<%-- What is this called ??? --%>
<asp:Label ID="MyLabel" runat="server" />
<% Response.Write("Hello World"); %>
我能想到的最好的术语是“Web 表单代码”。
最佳答案
明确地说,Microsoft 称它们为嵌入式代码块。
http://msdn.microsoft.com/en-us/library/ms178135.aspx
它们是通过在渲染阶段调用而嵌入到页面生命周期中的代码块。
关于c# - 在 ASP.NET 中, 'ASP' 代码叫什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/314397/