ad wrote:
When we create a new aspx in VS.Net, it will insert <div> tag inside
<form> tag, like below.
What is the function of <div> do?
---------------------------------------------------------------------------- ------------------------------------------
<form id="form1" runat="server">
<div>
</div>
</form>
what if you had a table, a couple of labels, and a few buttons that you
wanted to be rendered as a group, with a background color of beige and
you want to track the mouse as it moves within the group? To do that
you would code all those elements within a div, set the background
color style of the div and you would set the onmousedown property of
the div to a javascript function.
<div id="Div2" style="position :absolute; top:80px; left:45px;
z-index:10001;bac kground-color:beige;fon t-size:14;"
onmousedown="Di v2MouseDown( this );"
onmousemove="Di v2MouseMove( this );"
onmouseover="th is.style.backgr oundColor='red' ;
javascript
:Over Cx+=0; Div2MouseOver( this );"
onmouseout="jav ascript:Div2Cur sorOver=false;
this.style.back groundColor='be ige';" >
<SPAN STYLE="color: blue;text-decoration:unde rline;
font:italic normal bolder 12pt Arial;">Enter customer
name:</SPAN>
<br />
<INPUT TYPE=text VALUE="initial value" NAME="textbox2" SIZE=15 />
</div>
-Steve