Hacks RevisitedHacks exist in an ever-changing world. One day they are the cutting-edge, clever inventions of adeveloper with a need. Another day in t
In Listing 1-3, we’re primarily interested in whether the eating preference was Meat Eater or Vegetarianso we can extract values from the proper contr
To get started, create a new Web project and delete the Default.aspx page that is automatically created.We’ll re-create Default.aspx later as a conten
Figure 1-10After creating and modifying the Company.master Master Page, you can view the automatically gener-ated HTML code by clicking the HTML butto
<form id=”form1” runat=”server”><div><table border=”0” cellpadding=”0” cellspacing=”0” style=”width: 100%; height: 100%”><tr>&
Listing 1-5 (continued)ContentPlaceHolderID=”ContentPlaceHolder1” Runat=”Server”><h2>This is my content.</h2></asp:Content>The tw
No matter how query string parameters are presented, average users will have a hard time understanding.Instead, it would be much clearer to write the
Listing 1-6 (continued)<head runat=”server”><title>.NET Article Archive</title></head><body><form id=”form1” runat=”s
<asp:HyperLink ID=”hypMay” runat=”server” NavigateUrl=”~/YEAR/05”>May</asp:HyperLink><br /><asp:HyperLink ID=”hypJune”
Listing 1-8 (continued)SetMonths();}/// <summary>/// configure months to refer to proper page/// </summary>private void SetMonths(){foreac
<add url=”~/2006/01” mappedUrl=”~/MonthView.aspx?year=2006&month=01”/><add url=”~/2006/02” mappedUrl=”~/MonthView.aspx?year=2006&
solution that some people used was the Wizard Navigator in the User Interface Process (UIP) ApplicationBlock, created by the Microsoft Patterns and Pr
Listing 1-10 (continued)</Columns></asp:GridView><asp:ObjectDataSource ID=”ArticlesODS” runat=”server” SelectMethod=”GetArticles” TypeN
using System.Data;using System.Web;/// <summary>/// Summary description for ArticleData/// </summary>public class ArticleData{public void
Listing 1-13 (continued)<year>2005</year><month>02</month><title>Title2</title><content>This is the text of
private string m_year;public string Year{get { return m_year; }set { m_year = value; }}private string m_month;public string Month{get { return m_month
Using the ASP.NET v2.0 URL Mapping feature appears to be a great capability, but there is one catch:You can’t use regular expressions. The articles ex
Figure 1-2Figure 1-33Hacks Revisited04_597663 ch01.qxp 4/25/06 9:54 PM Page 3
5. Select View➪Properties Window to show the Properties window. In the Properties window, setthe HeaderText property to Menu Selector.6. Enlarge the W
Figure 1-514. Select the new Step 3 link that you just added to the Wizard control.15. Type Please Select Main Course: in the edit area.16. Drag and d
Figure 1-6Figure 1-76Chapter 104_597663 ch01.qxp 4/25/06 9:54 PM Page 6
This creates HTML with a Wizard that contains multiple steps. Listing 1-1 shows the HTML of this pagewith modifications made in the later parts of thi
Listing 1-1 (continued)Please select beverage:<br /><br /><asp:RadioButtonList ID=”RadioButtonList4” runat=”server”><asp:ListItem
Listing 1-2: Altering the sequential progress of a wizardprotected void Wizard1_NextButtonClick(object sender, WizardNavigationEventArgs e){if (Wizard
Comments to this Manuals