T
Tony Johansson
Hello!
Below is two alternatives presented. Is the two alternatives equivalent ?
As you can see the only difference is that the html element and the head
element is moved below the script element
Aternative 1
**********
<%@Page Language="C#" %>
<html>
<head>
<script runat="server">
void Button_Click(Object sender, EventArgs e)
{
Label1.Text = "Clicked at " + DateTime.Now.ToString();
}
</script>
</head>
....
....
....
</html>
Alternative 2
**********
<%@Page Language="C#" %>
<script runat="server">
void Button_Click(Object sender, EventArgs e)
{
Label1.Text = "Clicked at " + DateTime.Now.ToString();
}
</script>
<html>
<head>
...
</head>
....
....
....
</html>
//Tony
Below is two alternatives presented. Is the two alternatives equivalent ?
As you can see the only difference is that the html element and the head
element is moved below the script element
Aternative 1
**********
<%@Page Language="C#" %>
<html>
<head>
<script runat="server">
void Button_Click(Object sender, EventArgs e)
{
Label1.Text = "Clicked at " + DateTime.Now.ToString();
}
</script>
</head>
....
....
....
</html>
Alternative 2
**********
<%@Page Language="C#" %>
<script runat="server">
void Button_Click(Object sender, EventArgs e)
{
Label1.Text = "Clicked at " + DateTime.Now.ToString();
}
</script>
<html>
<head>
...
</head>
....
....
....
</html>
//Tony