User1716997844 posted
Hello!
a) I can't seem to find any resources on how to secure a page. I have a page "RepairReport.asp" I want it to be only assessible by either an Administrator or Employee who has login successfully via login.asp
b) I have a page repairReport.asp which has a form that looks like this:
<p align="center">Please complete the following form</p>
<form name="form1" method="post" action="">
<div align="center">
<table border="0" width="538">
<tbody><tr>
<th scope="row" align="right">Repair ID: </th>
<td><input name="textarea" id="textarea" value="" size="15" type="text" />
</td>
</tr>
<tr>
<th scope="row" align="right" height="55">Employee Name:</th>
<td><input name="textarea2" id="textarea2" value="" size="45" type="text" /></td>
</tr><tr>
<th scope="row" align="right" height="39"><p>Computer ID:</p></th>
<td><input name="textarea" value="" size="15" type="text" /></td>
</tr>
<tr>
<th scope="row" align="right">Problem Type:</th>
<td><input name="textarea" value="" size="15" type="text" />(HW or SW)</td>
</tr>
<tr>
<th scope="row" align="right">Description:</th>
<td><textarea name="textarea4" cols="45" rows="5" ></textarea></td>
</tr>
<tr>
<th scope="row" align="right">Repair:</th>
<td><textarea name="textarea4" cols="45" rows="5" ></textarea></td>
</tr>
<tr>
<th scope="row" align="right">Repair Status:</th>
<td><input name="textarea" value="" size="15" type="text" />(New, Repaired, Completed)</td>
</tr>
<tr>
<th scope="row"> </th>
I wanted to validate forms but what I don't understand each form does not have unique names. I were to response.Request form it only has 3 names:
- textarea
- textarea2
- textarea4
How am I suppose to validate each and each form? ie. if I were to validate the Repair ID like: "Repair id must have R-xxx format where xxx is any number" how am I suppose to call that specific form?
And finally that same page (repairReport.asp) has a
<h4 align="center"><font color="red">All Error Messages Go Here</font></h4>
How am I supposed to embed the error though the validation on page instead of redirecting it to a different page? I don't want it to go to a different page and state something like: "Error. Click back in your browser, and fill it out properly!"
Thanks for your time!
Taz.