Hello Everyone,<div><br></div><div>I am making a simple index.php file which will allow a web user to enter his $phoneNumb, $dialNumb, and callerID ($spoofNumb) and get the call bridged. Following is the index.php and the contents of extensions_custom.conf. When I submit the form nothing happens. I don't even see Manager Connected msg. Your input will be much appreciated. I am thinking I have some syntax problem.</div>
<div><br></div><div><span class="Apple-style-span" style="color: rgb(51, 51, 51); font-family: 'Lucida Grande', 'Trebuchet MS', Verdana, Helvetica, Arial, sans-serif; font-size: 13px; line-height: 18px; "><span style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; font-weight: bold; ">/etc/asterisk/extensions_custom.conf</span></span></div>
<div><font class="Apple-style-span" color="#333333" face="'Lucida Grande', 'Trebuchet MS', Verdana, Helvetica, Arial, sans-serif"><span class="Apple-style-span" style="line-height: 18px;"><b><span class="Apple-style-span" style="color: rgb(46, 139, 87); font-family: Monaco, 'Andale Mono', 'Courier New', Courier, mono; font-size: 12px; font-weight: normal; line-height: 15px; ">[testphp]<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
exten => _X.,1,Answer()<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">exten => _X.,n,Dial(SIP/testTrunk/${EXTEN})<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
exten => _X.,n,Hangup()</span></b></span></font></div><div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;"><br>
</span></font></div><div><font class="Apple-style-span" color="#333333" face="'Lucida Grande', 'Trebuchet MS', Verdana, Helvetica, Arial, sans-serif"><span class="Apple-style-span" style="line-height: 18px;"><b><br>
</b></span></font></div><div><font class="Apple-style-span" color="#333333" face="'Lucida Grande', 'Trebuchet MS', Verdana, Helvetica, Arial, sans-serif"><span class="Apple-style-span" style="line-height: 18px;"><b><br>
</b></span></font></div><div><font class="Apple-style-span" color="#333333" face="'Lucida Grande', 'Trebuchet MS', Verdana, Helvetica, Arial, sans-serif"><span class="Apple-style-span" style="line-height: 18px;"><b>*****************************************************************************************************</b></span></font></div>
<div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;"><span class="Apple-style-span" style="color: rgb(51, 51, 51); font-family: 'Lucida Grande', 'Trebuchet MS', Verdana, Helvetica, Arial, sans-serif; font-size: 13px; line-height: 18px; font-weight: bold; ">/var/www/html/clickncall/index.php</span></span></font></div>
<div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;"><html><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
<head><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><title>ClicknCall</title><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
</head><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><body><br><br><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
<div align="center"><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
<?php<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
$sys_ip = "127.0.0.1";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">$User_str = "testphp";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
$Secret_str = "testphp";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
if ($_POST['x']) {<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">$oSocket = fsockopen($sys_ip, 5038, $errnum, $errdesc) or die("Connection to host failed");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
<br></span></font></div><div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;">fputs($oSocket, "Action: login\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "Username: $User_str\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">fputs($oSocket, "Secret: $Secret_str\r\n\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "Events: off\r\n\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">fputs($oSocket, "Action: originate\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "Channel: SIP/testTrunk/$phoneNumb\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "Exten: $dialNumb\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">fputs($oSocket, "Context: testphp\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "Priority: 1\r\n\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">fputs($oSocket, "Timeout: 10000\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "CallerId: $spoofNumb\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">fputs($oSocket, "Async: true\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fputs($oSocket, "Action: Logoff\r\n\r\n");<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
fclose($oSocket);<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
print $_POST['x'];<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
} else {<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "> print "<form method=\"post\"action=\"$_SERVER[PHP_SELF]\">";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
print "<br>";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "> print "PHONE Number: <input type=\"text\"name=\"phoneNumb\">";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
print "<br>";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "> print "PARTY Number: <input type=\"text\"name=\"dialNumb\">";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
print "<br>";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "> print "FORGE Number: <input type=\"text\"name=\"spoofNumb\">";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
print "<br>";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "> print "<input type=\"Submit\" value=\" Dial \">";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
print "</form>";<br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
} ?><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
</div><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; "></body><br style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">
</html></span></font></div><div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;"><br>
</span></font></div><div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;">************************************************************************************</span></font></div>
<div><font class="Apple-style-span" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono"><span class="Apple-style-span" style="line-height: 15px; "><b><span class="Apple-style-span" style="font-size: large;">/etc/asterisk/manager_custom.conf</span></b></span></font></div>
<div><font class="Apple-style-span" color="#2E8B57" face="Monaco, 'Andale Mono', 'Courier New', Courier, mono" size="3"><span class="Apple-style-span" style="font-size: 12px; line-height: 15px;"><div>[testphp]</div>
<div>secret = testphp</div><div>deny=<a href="http://0.0.0.0/0.0.0.0">0.0.0.0/0.0.0.0</a></div><div>permit=<a href="http://127.0.0.1/255.255.255.0">127.0.0.1/255.255.255.0</a></div><div>read = system,call,log,verbose,command,agent,user</div>
<div>write = system,call,log,verbose,command,agent,user</div><div><br></div><div><br></div><div>Thanks,</div><div><br></div><div><br></div></span></font></div>