We can use ASP.NET 2.0's URL mapping feature to provide a friendly URL, like ~/Beverages.aspx. The following
...
...
mappedUrl="~/ProductsByCategory.aspx?CategoryID=1&CategoryName=Beverages" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=2&CategoryName=Condiments" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=3&CategoryName=Confections" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=4&CategoryName=Dairy+Products" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=5&CategoryName=Grains+and+Cereals" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=6&CategoryName=Meat+and+Poultry" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=7&CategoryName=Produce" />
mappedUrl="~/ProductsByCategory.aspx?CategoryID=8&CategoryName=Seafood" />
No comments:
Post a Comment