1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
|
<%
Dim Animals, name
Animals=Request.Form("Animals")
name=Request.Form("name")
%>
<form method="post">
<p>Which of these Animals do you prefer:</p>
<input type="checkbox" name="Animals" value="Dogs"
<%if instr(Animals,"Dog") then%> checked <% end if %>>
Dogs
<br>
<input type="checkbox" name="Animals" value="Cats"
<%if instr(Animals,"Cat") then%> checked <% end if %>>
Cats
<br>
<input type="checkbox" name="Animals" value="Horses"
<%if instr(Animals,"Horse") then%> checked <% end if %>>
Horses
<br>
<input type="checkbox" name="Animals" value="Cows"
<%if instr(Animals,"Cow") then%> checked <% end if %>>
Cows
<br>
Your name: <INPUT TYPE="text" NAME="name" Value=<%=name%>>
<input type="submit" value="Submit">
</form>
<% if name<>"" then%>
<p>Your name is: <%=name%></p>
<% end if %>
<% if Animals<>"" then%>
<p>Your favorits animals are: <%=Animals%></p>
<% end if %>
|
|
|