<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<body>
<form method="post">
<table width="779" border="1" cellspacing="0" cellpadding="10">
<tr>
<th scope="row">Enter String :</th>
<td><textarea name="txtstr" id="txtstr"></textarea></td>
</tr>
<tr>
<th colspan="2" scope="row"><input type="submit" name="btnsubmit" id="btnsubmit" value="Submit" /></th>
</tr>
</table>
</form>
</body>
</html>
<?php
include("email.php");
$email=array();
if(isset($_POST['btnsubmit'])){
$mail=$_POST['txtstr'];
$a=explode("\n",$mail);
foreach($a as $val){
$arr=explode(" ",$val);
foreach($arr as $m){
$f=validate($m);
if($f)
$email[]=$m;
}
}
echo '<br/>There are '.count($email).' emails in this string.';
}
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<body>
<form method="post">
<table width="779" border="1" cellspacing="0" cellpadding="10">
<tr>
<th scope="row">Enter String :</th>
<td><textarea name="txtstr" id="txtstr"></textarea></td>
</tr>
<tr>
<th colspan="2" scope="row"><input type="submit" name="btnsubmit" id="btnsubmit" value="Submit" /></th>
</tr>
</table>
</form>
</body>
</html>
<?php
include("email.php");
$email=array();
if(isset($_POST['btnsubmit'])){
$mail=$_POST['txtstr'];
$a=explode("\n",$mail);
foreach($a as $val){
$arr=explode(" ",$val);
foreach($arr as $m){
$f=validate($m);
if($f)
$email[]=$m;
}
}
echo '<br/>There are '.count($email).' emails in this string.';
}
?>
No comments:
Post a Comment