PC Review


Reply
Thread Tools Rate Thread

Combing html and server controls

 
 
Will
Guest
Posts: n/a
 
      2nd Aug 2008
I'm interested in people's views on combining standard html controls
and asp.net server controls.

I've seen some applications where server controls were only used where
server side processing and control were required, combining them with
standard html for the static part of the page. Others have constructed
the page using almost entirely server controls (for example, using
asp:Label controls for text that will not change).

Is there a consensus on best practice here? For myself, I err on the
side of using html controls as much as possible (without the runat
attribute) as there is more consistency to how they are rendered. and
are easier to control with CSS.

Thanks
 
Reply With Quote
 
 
 
 
bruce barker
Guest
Posts: n/a
 
      2nd Aug 2008
use asp.net controls if you want abstraction from html and like the
"fake" event processing of asp.net. use html controls if you are writing
client code, or are concered about the html generated.

if you know html, you might want to switch to MVC toolkit, which
eliminates the fake events, and allows unit tests.

-- bruce (sqlwork.com)

Will wrote:
> I'm interested in people's views on combining standard html controls
> and asp.net server controls.
>
> I've seen some applications where server controls were only used where
> server side processing and control were required, combining them with
> standard html for the static part of the page. Others have constructed
> the page using almost entirely server controls (for example, using
> asp:Label controls for text that will not change).
>
> Is there a consensus on best practice here? For myself, I err on the
> side of using html controls as much as possible (without the runat
> attribute) as there is more consistency to how they are rendered. and
> are easier to control with CSS.
>
> Thanks

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
HTML controls instead of .Net server controls =?Utf-8?B?Q2hyaXMgRGF2b2xp?= Microsoft ASP .NET 3 16th Sep 2006 06:24 PM
HTML Server Controls! Adam Knight Microsoft ASP .NET 2 7th Sep 2005 01:16 AM
Difference in Web server Controls and HTML Server Controls =?Utf-8?B?c2lhag==?= Microsoft ASP .NET 7 7th Mar 2005 07:15 PM
Communicating client side information to the server - HTML controls vs Server controls Emily Microsoft Dot NET Framework 1 12th Mar 2004 09:06 PM
difference between HTML controls, HTML server controls , ASP.Net controls? Hari Microsoft Dot NET 1 3rd Jan 2004 11:11 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:31 PM.