All pastes #469181 Raw Edit

Mine

public text v1 · immutable
·published 2007-05-03 16:30 UTC
rendered paste body
// FORM

                            <tr> 
                              <td height="24" colspan="4" valign="top" class="input">
							  <form action="tld-check.php" method="post" name="check">
							  <input type="text" name="domain" size="18"> 
                                <select name="tld" size="1">
                                  <option selected>.com</option>
                                  <option>.net</option>
                                  <option>.org</option>
                                  <option>.biz</option>
                                </select>
								</form>
								</td>
                            </tr>
                            <tr> 
                              <td width="134" rowspan="2" valign="top" class="domaintxt2">Register 
                                a Domain at <span class="style5">$<font size="4">7</font>.95*/ Year</span></td>
                              <td width="14" height="42"></td>
                              <td width="61" valign="middle">
<input type="image" src="images/search-but.gif" width="53" height="21" onclick="document.check.submit();" name="submit"/>
							  </td>
                              <td width="15"></td>
                            </tr>


// tld-check.php

<?php
if (isset($_REQUEST['submit']) && isset($_REQUEST['domain']) && isset($_REQUEST['tld'])) {
	$domain = $_REQUEST['domain'] . '.' . $_REQUEST['tld'];
	$site = file_get_contents("http://isfree.schlundtech.de/cgi-bin/isfree.cgi?domain=$domain&lang=EN");

	if (strpos($site, 'is still available') !== false) {	
		$results = "<b>$domain is Available</b>";
	} else {
		$results = "<b>$domain is Not Available</b>";
	}
}
?>	

<?php var_dump($_POST); ?>