Standard ASP.NET Webforms (which is what I guess you'll be using) doesn't give you total control over your HTML - you're not programming directly in HTML and markup, but against an abstracted "webform" model. E.g. you use and create server-side objects like data source (to grab your data), a gridview etc. - and the server control then really renders out the HTML to be sent back to the customer's browser.
So you might have a SQL data source to reach into your SQL Server table and grab the data:
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:TestConnectionString2 %>"
SelectCommand="SELECT [Lastname], [Address], [zipcode], [city],
[country], [email] FROM [Addresses]">
</asp:SqlDataSource>
and then hook that up to a data-bound ListView on your ASP.NET form:
<asp:ListView ID="ListView1" runat="server" DataSourceID="SqlDataSource1">
<ItemTemplate>
<span style="background-color: #E0FFFF;color: #333333;">Lastname:
<asp:Label ID="LastnameLabel" runat="server" Text='<%# Eval("Lastname") %>' />
<br />
Address: <asp:Label ID="AddressLabel" runat="server" Text='<%# Eval("Address") %>' /><br />
zipcode: <asp:Label ID="zipcodeLabel" runat="server" Text='<%# Eval("zipcode") %>' /><br />
city: <asp:Label ID="cityLabel" runat="server" Text='<%# Eval("city") %>' /><br />
country: <asp:Label ID="countryLabel" runat="server" Text='<%# Eval("country") %>' /><br />
email: <asp:Label ID="emailLabel" runat="server" Text='<%# Eval("email") %>' />
<br /><br /></span>
</ItemTemplate>
<EmptyDataTemplate>
<span>No data was returned.</span>
</EmptyDataTemplate>
<LayoutTemplate>
<div ID="itemPlaceholderContainer" runat="server"
style="font-family: Verdana, Arial, Helvetica, sans-serif;">
<span ID="itemPlaceholder" runat="server" />
</div>
<div style="text-align: center;background-color: #5D7B9D;
font-family: Verdana, Arial, Helvetica, sans-serif;color:#FFFFFF;">
</div>
</LayoutTemplate>
</asp:ListView>
Check out the official ASP.NET website which has plenty of articles, tutorials, screen casts and demos on how to get started on ASP.NET webform development.
If you want total control over your markup, you should check out ASP.NET MVC which is a new concept for ASP.NET developers, but which might be a lot more along the lines of what you already know from PHP programming. Here, you do have total control over your HTML and every bit and byte being sent back to the browser.
Marc