Solved

runat=server tag in html

Posted on 2010-09-14
2
404 Views
Last Modified: 2012-05-10
Does adding the id and runt=server tag, increase load time or affect performance in any way?
for eg if i create an element as:
<div id="mydiv" runat="server">
vs
<div class="mydiv">

affect load time or page size in any way. any suggestions would b great.


0
Comment
Question by:TrialUser
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 52

Accepted Solution

by:
Carl Tawn earned 250 total points
ID: 33673080
It shouldn't affect page size directly. Load time will take a minor hit because the parser will create a server-side object to represent the element rather than simply copyingt the markup to the output stream.

However, the hit will be negligible so shouldn't prevent you converting to a server-side element if you need to access it dynamicaly.
0
 
LVL 17

Assisted Solution

by:mreuring
mreuring earned 250 total points
ID: 33673082
I've seen very interesting articles on load time, most of which suggest that the performance of a backend-system is in most case negligible to what's happening during transmission and rendering of a page. So, runat="server" should not have a noticeable impact on performance at all. Removing the attribute will actually make your .net application fail (or it should, since this attribute indicates that the html-tag needs some attention from your backing bean, or whatever it's called on .Net :))

Anyways, client-side it will have 0 impact, it gets ignored.
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses four methods for overlaying images in a container on a web page
Find out what you should include to make the best professional email signature for your organization.
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

689 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question