Click here to Skip to main content
15,885,875 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
<html>
<body>


$ipAddress=$_SERVER['REMOTE_ADDR'];
$macAddr=false;
$out_put="";
//$SP_VAL="";
//echo "Your IP address is : $ipAddress";
#run the external command, break output into lines
$arp=`arp -a $ipAddress`;
$lines=explode("\n", $arp);

#look for the output line describing our IP address
foreach($lines as $line)
{
$cols=preg_split('/\s+/', trim($line));
if ($cols[0]==$ipAddress)
{
$macAddr=$cols[1];
}
}

?>


if(isset($_POST['webpanel'])){
$mobileno=$_POST['mobileno'];
$fname=$_POST['fname'];
$email=$_POST['femail'];
$fmessage=$_POST['fmessage'];
$colorRadio=$_POST['colorRadio'];
$demo1=$_POST['demo1'];
$flag="CALL_ORIGIN";
$client="GALACTIC";

$mysqli = mysqli_connect("localhost", "root", "", "call_conference");

$call = $mysqli->prepare('CALL CALL_ORIGIN(?, ?, ?, ?, ?, ?, ?, ?, ?, ?,@out_put)');
$call->bind_param('ssssssssss',$mobileno,$flag,$fname,$email,$fmessage,$ipAddress,$macAddr,$colorRadio,$demo1,$client);
$call->execute();

$select = $mysqli->query('SELECT @out_put');
$result = $select->fetch_assoc();
$SP_VAL = $result['@out_put'];
echo "Result from SP procOutput_sum:::::$SP_VAL";

if(empty($mobileno) || empty($fname)){
echo "SP OUT_VAL:$output";
echo "<label class='err'>All field is required</label>";
}

elseif(!is_numeric($mobileno)){
echo "<label class='err'>Mobile no must be numeric</label>";
}
else{


echo "  Your IP address is : $ipAddress and Your Mac address is:$macAddr and CALL_SCHEDULER_TIME::: $demo1";

?>

}
?>

<body style="background:white;">

Hi



Your call is transferred to our Server




echo "Result from SP procOutput_sum:::::$SP_VAL";

$mysqli = mysql_connect("localhost", "root", "", "call_conference");
if (!$mysqli) {
die('Could not connect: ' . mysql_error());
}

?>
$select="select call_status from tbl_call_origin where id='$SP_VAL'";
echo $select;
$data=mysql_query($select);
$row=mysql_fetch_array($data);

//echo $row['call_status'];
?>



</body>
</html>
Posted
Comments
Sergey Alexandrovich Kryukov 15-Jul-14 12:54pm    
Not clear. You did not explain what is the problem; this is just the code dump, not really helpful.
—SA
Member 10947687 16-Jul-14 1:29am    
sir i jst want to know how we can get the call status of the call from my id.

This is my whole code sir..here am using select query there i jst want to print call status from database using id



prepare('CALL CALL_ORIGIN(?, ?, ?, ?, ?, ?, ?, ?, ?, ?,@out_put)');
$call->bind_param('ssssssssss',$mobileno,$flag,$fname,$email
,$fmessage,$ipAddress,$macAddr,$colorRadio,$demo1,$client);
$call->execute();

$select = $mysqli->query('SELECT @out_put');
$result = $select->fetch_assoc();
$SP_VAL = $result['@out_put'];
echo "Result from SP procOutput_sum:::::$SP_VAL";

if(empty($mobileno) || empty($fname)){
echo "SP OUT_VAL:$output";
echo "<label class='err'>All field is required</label>";
}
elseif(!is_numeric($mobileno)){
echo "<label class='err'>Mobile no must be numeric</label>";
}
else{

echo "  Your IP address is : $ipAddress and Your Mac address is:$macAddr and

CALL_SCHEDULER_TIME::: $demo1";
?>


<body style="background:white;">

Hi

<br/>

Your call is transferred to our Server





This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900