In the generated asp.net code from visual web developer 2010, I see the following code:
<%@ Control Language="C#" ClassName="Header" %>
<asp:Panel ID="Panel1" runat="server">
<img alt="xxx"
src="Images/bird.jpg"
width="800" height="110"/>
</asp:Panel>
<asp:Panel id="menuPanel" runat="server">
<a href="1.aspx">Home</a> |
<a href="2.aspx">Titles</a> |
<a href="3.aspx">Authors</a> |
<a href="4.aspx">Publishers</a>
</asp:Panel>
- What is the meaning of
<%@in
asp.net? - What is the meaning of
<asp:Panel?
I see other examples, <asp:Button <asp:Label, etc.
Thank you
ASP.NET server instructions are enclosed by angled brackets:
<% ... %>; they tell ASP.NET to process their contents before sending a page to the client’s browser.@identifies a directive, which do a variety of things but usually provide some instructions about what to do with the .aspx or .ascx file:PageandControlare two of the most commonly-used directives.<asp:Panel>is an ASP.NET WebControl. Web controls are server-side representations of HTML elements. They allow you to manipulate the page in a code-behind file that’s executed on the server before being delivered to the client’s browser.For example, ASP.NET renders
Paneltags as<div>elements, and rendersButtontags as<input>elements.