'Programming/ASP.NET 4.0'에 해당되는 글 14건

  1. URL routing
  2. Response.RedirectPermanent()
  3. ASP.NET 4.0 Quick Video Summary
  4. ASP.NET 4.0 Resource

URL routing


URL Routing

1. Add global.aspx
- add RegisterRoutes function


2. Add default.asxp

Add two linkbuttons as below


3. Add List.aspx
Add two labels. One of them will say the routhing values for "type".

list.aspx

list.aspx.vb



Response.RedirectPermanent()

Response.RedirectPermanent()

Response.Redirect는 302를 브라우져에게 되돌려 주는데, 이 뜻은 요청된 리소스가 임시적으로 다른 장소로 이동했다는 의미이다. 그러나 RedirectPermanent()는 301을 되돌려 주며,의미하는 바는 영원히 신규 페이지로 이동되었다는 것을 의미한다.

따라서, Response.Redirect를 사용하면 웹서치엔진(구글 같은)들은 이동하기전의 이전 페이지를 기록하며, RedirectPermanent()를 사용하면 이동된 신규 페이지를 기억하게 된다.

[VB.NET]
Protected Sub Application_BeginRequest(ByVal sender As Object, _
   
ByVal e As EventArgs)
   
    If Request.FilePath = "/our-products.aspx" Then
        Response.Redirect("/products.aspx", True)
    End If
    If Request.FilePath = "/about-us.aspx" Then
        Response.RedirectPermanent("/about.aspx", True)
    End If
End Sub


(참조)
http://weblogs.asp.net/gunnarpeipman/archive/2009/05/27/asp-net-4-0-seo-features-response-permanentredirect.aspx

ASP.NET 4.0 Quick Video Summary

1. Chart - 다양한 차트 컨트롤들이 추가되었다. 사용하기 쉽다.
2. MetaData - Page.MetaKeywords와 Page.MetaDescription를 이용하여 페이지에서 동적으로 메타 데이터를 설정하고, 이는 자동으로 HTML에 표시되어진다.

ASP.NET 4.0 Resource