Tuesday, April 3, 2007

Literal vs Label

When working with .NET, you may wonder the difference between Literal and Label.

Actually, when both controls are converted to become HTML, Label will add a pair of <span></span> tag, while Literal keeps everything unchanged.

So most of the time if would be better to use Literal instead of Label for the sake of simplicity.

No comments:

Post a Comment

CSP on Apache

To add CSP to root if sort of funny. The following will NOT work for most cases !!     <LocationMatch "^/$">        Header s...