<script runat="server">
Sub submit(sender As Object, e as EventArgs)
if name.value<>"" then
p1.InnerHtml="欢迎" & name.value & "!"
end if
End Sub
</script>
<html>
<body>
<form runat="server">
请输入您的名字:<input id="name" type="text" size="30" runat="server" />
<br /><br />
<input type="submit" value="提交" OnServerClick="submit" runat="server" />
<p id="p1" runat="server" />
</form>
</body>
</html>