<html>
<head>
<title>HIOX Scripts - HMAILER Registration page</title>
</head>
<body>
<!-- Welcome to the scripts database of HIOX INDIA -->
<!-- This tool is developed and a copyright -->
<!-- product of HIOX INDIA. -->
<!-- For more information visit http://www.hscripts.com -->
<?php
include 'params.php';
$link = mysql_connect($hostn, $usern,$passn);
if (!$link) {
die('Could not connect: ' . mysql_error());
}
mysql_select_db($dbname,$link);
?>
<table width=80% cellpadding=0 cellspacing=0 align=center>
<tr><td bgcolor="#cfffcf" align=center>
<br>
<b>Registration Page</b>
<br><br>
</td></tr>
<tr><td bgcolor="#efffef">
<br><br><br>
<div align=left style="padding-left: 150px;">
<?php
$mailid = $_POST['mail'];
$testval = true;
$result3 = mysql_query("select * from mailid where name like '$mailid'",$link);
if($result3)
{
while ($row = mysql_fetch_array($result3,MYSQL_ASSOC))
{
$usercheck = mysql_result($result3,0,"name");
if($usercheck == $user)
{
$testval = false;
echo("<font color=\"#AF0000\">");
echo("This Mail ID is already registered for Updates<br>");
echo("Please enter a different id<br>");
echo("<br><br>");
echo("</font>");
echo("<font color=\"#1F8605\">");
echo("Thanks for your interest,<br>");
echo("HIOX INDIA Team<br>");
echo("</font>");
}
}
if($testval == true)
{
$illegal=array('.com',".net",'.org','.biz','.coop','.info','.museum','.name','.pro','.edu','.gov','.int','.mil','.ac','.ad','.ae','.af','.ag','.ai','.al','.am','.an','.ao','.aq','.ar','.as','.at','.au','.aw','.az',
'.ba','.bb','.bd','.be','.bf','.bg','.bh','.bi','.bj','.bm','.bn','.bo','.br','.bs','.bt','.bv','.bw','.by','.bz','.ca','.cc','.cd','.cf','.cg','.ch','.ci','.ck','.cl','.cm','.cn','.co','.cr','.cu','.cv','.cx','.cy','.cz',
'.de','.dj','.dk','.dm','.do','.dz','.ec','.ee','.eg','.eh','.er','.es','.et','.fi','.fj','.fk','.fm','.fo','.fr','.ga','.gd','.ge','.gf','.gg','.gh','.gi','.gl','.gm','.gn','.gp','.gq','.gr','.gs','.gt','.gu','.gv','.gy',
'.hk','.hm','.hn','.hr','.ht','.hu','.id','.ie','.il','.im','.in','.io','.iq','.ir','.is','.it','.je','.jm','.jo','.jp','.ke','.kg','.kh','.ki','.km','.kn','.kp','.kr','.kw','.ky','.kz','.la','.lb','.lc','.li','.lk','.lr','.ls','.lt','.lu','.lv','.ly',
'.ma','.mc','.md','.mg','.mh','.mk','.ml','.mm','.mn','.mo','.mp','.mq','.mr','.ms','.mt','.mu','.mv','.mw','.mx','.my','.mz','.na','.nc','.ne','.nf','.ng','.ni','.nl','.no','.np','.nr','.nu','.nz','.om',
'.pa','.pe','.pf','.pg','.ph','.pk','.pl','.pm','.pn','.pr','.ps','.pt','.pw','.py','.qa','.re','.ro','.rw','.ru','.sa','.sb','.sc','.sd','.se','.sg','.sh','.si','.sj','.sk','.sl','.sm','.sn','.so','.sr','.st','.sv','.sy','.sz',
'.tc','.td','.tf','.tg','.th','.tj','.tk','.tm','.tn','.to','.tp','.tr','.tt','.tv','.tw','.tz','.ua','.ug','.uk','.um','.us','.uy','.uz','.va','.vc','.ve','.vg','.vi','.vn','.vu','.ws','.wf','.ye','.yt','.yu','.za','.zm','.zw');
$garb=array();
$pos =strpos($mailid,"@");
$pos1 =strpos($mailid,".");
//echo($user);
echo("<font color=red>");
$maild = "wrong";
foreach($illegal as $k)
{
if(($j=strpos($mailid,$k))!==false)
{
//echo("<br>".$k);
if($pos == FALSE || $pos1 == FALSE || $pos==($pos1-1) || $pos1==($pos-1) || $pos1<$pos )
{
echo($pos);
echo($pos1);
$maild = "wrong";
}
else
{
$maild = "correct";
}
}
}
if($maild == "correct")
{
$qers = "insert into mailid values('','$mailid','no-group')";
//echo $qers;
$result = mysql_query($qers,$link);
if($result)
{
echo("<div align=left style=\"margin-left: 25px; font-size: 14px;\"><font color=\"#108C00\">");
echo("<b>Dear Subscriber</b>,<br><br>");
echo("Thanks for your registration with us<br>");
echo("your mailid <b><font color=#925581>$mailid</font></b> has been added in to our list.<br>");
echo("You will receive updates from us.<br>");
echo("<br>");
echo("You can unregister by sending a mail to us<br>");
echo("<br>");
echo("Thanks for you interest,<br>");
echo("Support Team");
echo("</font></div>");
}
}
else
{
echo("<br><br><br><br><br><br>");
echo("Error : Give a proper mail id");
echo("<br><br><br><br><br><br>");
}
}
}
?>
<br><br><br><br>
</div>
<div align=right>
a product of <a href=http://www.hscripts.com style="color:green; text-decoration: none;">hscripts.com</a>
</div>
<br><br>
</td></tr>
</table>
</body>
</html>