PDA

View Full Version : Submit to whois.php from another page



harryhood
06-15-2005, 08:35 PM
Is it possible to have a form on another page than the whois.php page ans submit the domain and tld directly from the form on the other page?

I've been trying without any luck. Here is the form that I have:


<form name='whois_search' method='POST' action="/whois.php" style="margin-bottom: 0px;">
<input type='hidden' name='page' value='WhoisSearch'>

<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="20" colspan="3" class="darkgray">Check the avilability of your domain </td>
</tr>
<tr>
<td width="25%" height="20"><div align="center" class="darkgray">www.</div></td>
<td width="35%" height="20"><input name="domain" type="text" class="grey" size="12"></td>
<td width="40%" height="20"><div align="center">
<select name="ext0" class="grey">
<option>.com</option>
<option>.net</option>
<option>.org</option>
<option>.biz</option>
</select>
</div></td>
</tr>
<tr>
<td colspan="3">
<div align="right">
<input name="Submit2" id='Submit' type="submit" class="formfield" value="search">
</div></td>
</tr>
</table>

Patrick
06-16-2005, 01:18 AM
Yes, it is possible. It looks like your html is incorrect.

Try this instead:

<form name='whois_search' method='POST' action="/whois.php" style="margin-bottom: 0px;">
<input type='hidden' name='page' value='WhoisSearch'>

<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="20" colspan="3" class="darkgray">Check the avilability of your domain </td>
</tr>
<tr>
<td width="25%" height="20"><div align="center" class="darkgray">www.</div></td>
<td width="35%" height="20"><input name="domain" type="text" class="grey" size="12"></td>
<td width="40%" height="20"><div align="center">
<select name="ext0" class="grey">
<option value="com">.com</option>
<option value="net">.net</option>
<option value="org">.org</option>
<option value="biz">.biz</option>
</select>
</div></td>
</tr>
<tr>
<td colspan="3">
<div align="right">
<input name="Submit2" id='Submit' type="submit" class="formfield" value="search">
</div></td>
</tr>
</table>

** NOTE how I specified the value for each option and how that value is the TLD without the first dot, so com instead of .com, net instead of .net, etc...

harryhood
06-16-2005, 08:12 AM
Great thank you. That fixed it.

This is certainly a great whois script.