Java Reference
In-Depth Information
Now point your browser to http://localhost/ ch14 _ example1.html , and you should see something
like Figure 14-6.
Ty p e jmcpeak into the Username field and click the Check Availability link next to it. You'll see an
alert box like the one shown in Figure 14-7.
figure 14-6  
figure 14-7  
Now type someone@xyz.com in the e‐mail field and click the Check Availability link next to it. Again,
you'll be greeted with an alert box stating that the e‐mail's already in use. Now input your own
username and e‐mail into these fields and click the appropriate links. Chances are an alert box will
tell you that your username and/or e‐mail is available (the usernames jmcpeak and pwilton and the
e‐mails someone@xyz.com an d someone@zyx.com ar e the only ones used by the application).
The body of this HTML page contains a simple form whose fields are contained within a table. Each
form field exists in its own row. The first two rows contain the fields you're most interested in: the
Username and Email fields:
<form>
<table>
<tr>
<td class="fieldname">
Username:
</td>
<td>
<input type="text" id="username" />
</td>
<td>
<a id="usernameAvailability" href="#">Check Availability</a>
</td>
</tr>
<tr>
<td class="fieldname">
Email:
</td>
<td>
Search WWH ::




Custom Search