<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=us-ascii" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.19046"></HEAD>
<BODY>
<DIV dir=ltr align=left><FONT color=#0000ff size=2 face=Arial><SPAN
class=282440611-10052011>Why do I get the feeling that this guy wants someone to
write it for him for free? </SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT color=#0000ff size=2 face=Arial><SPAN
class=282440611-10052011></SPAN></FONT> </DIV>
<DIV dir=ltr align=left><FONT color=#0000ff size=2 face=Arial><SPAN
class=282440611-10052011>Especially seeing has how he has never posted what
anyone who has tried to help, have requested.</SPAN></FONT></DIV>
<DIV> </DIV>
<DIV><SPAN class=282440611-10052011><FONT color=#0000ff size=2 face=Arial>Maybe
Mr. Katta needs to google for 'dcap'?</FONT></SPAN></DIV>
<DIV><SPAN class=282440611-10052011><FONT color=#0000ff size=2
face=Arial></FONT></SPAN> </DIV>
<DIV><SPAN class=282440611-10052011><FONT color=#0000ff size=2
face=Arial></FONT></SPAN> </DIV>
<DIV><BR></DIV>
<DIV dir=ltr lang=en-us class=OutlookMessageHeader align=left>
<HR tabIndex=-1>
<FONT size=2 face=Tahoma><B>From:</B> asterisk-users-bounces@lists.digium.com
[mailto:asterisk-users-bounces@lists.digium.com] <B>On Behalf Of </B>mahesh
katta<BR><B>Sent:</B> 10 May 2011 11:49<BR><B>To:</B> Asterisk Users Mailing
List - Non-Commercial Discussion<BR><B>Subject:</B> Re: [asterisk-users]
OUTBOUND CALLER ID<BR></FONT><BR></DIV>
<DIV></DIV>Sir,<BR>A.J.Stiles<BR><BR>This dialplan is not working . when I
called to out of box . <BR><BR><BR>
<DIV class=gmail_quote>On Tue, May 10, 2011 at 2:00 PM, A J Stiles <SPAN
dir=ltr><<A
href="mailto:asterisk_list@earthshod.co.uk">asterisk_list@earthshod.co.uk</A>></SPAN>
wrote:<BR>
<BLOCKQUOTE
style="BORDER-LEFT: rgb(204,204,204) 1px solid; MARGIN: 0pt 0pt 0pt 0.8ex; PADDING-LEFT: 1ex"
class=gmail_quote>
<DIV class=im>On Tuesday 10 May 2011, mahesh katta wrote:<BR>>
sir,<BR>><BR>> Below configuration i wase made in server . but this is
not working.<BR>><BR>><BR>> exten =>
_90XXXXXXXXX,1,NoOp(${CALLERID(num)})<BR>> exten =>
_90XXXXXXXXX/5001,2,Set(CALLERID(name)=44578999)<BR>> exten =>
_90XXXXXXXXX,3,AGI(agi://<A href="http://127.0.0.1:4577/call_log"
target=_blank>127.0.0.1:4577/call_log</A>)<BR>> exten =>
_90XXXXXXXXX/5001,4,Set(CALLERID(num)=44578999)<BR>> exten =><BR>>
_90XXXXXXXXX,5,MixMonitor(/var/spool/asterisk/astrec/${TIMESTAMP}-${CALLERI<BR>>DNUM}-${EXTEN}-${UNIQUEID}.gsm|av(0)V(0))
exten =><BR>> _90XXXXXXXXX,6,Dial(${TRUNK}/${EXTEN:1},,tTo)<BR>>
exten => _90XXXXXXXXX,7,Hangup<BR><BR></DIV>OK. Here's what I see
going on.<BR><BR>When you dial 90XXXXXXXXX:<BR>Stage 1: The NoOp() will
just write the CALLERID(num) to the console. (This<BR>initially will be
the originating extension number.)<BR>Stage 2: If the originating
extension is 5001, the CALLERID(name) will be set<BR>to 44578999.<BR>Stage 3:
Calls an AGI script, presumably to log the call outside of the
CDR<BR>database.<BR>Stage 4: If the originating extension is 5001, the
CALLERID(num) will be set<BR>to 44578999.<BR>Stage 5: Starts a
recording.<BR>Stage 6: Passes the dialled number, skipping 1 digit from
the beginning<BR>(i.e. the initial 9 for the outside line), to a Dial()
command.<BR>Stage 7: Hangs up.<BR><BR>I'm not at all convinced that this
is right, especially as you are mixing<BR>destination extensions with and
without originating extensions. And, the way<BR>this bit is written, it
will only ever set the outgoing caller ID for<BR>extension 5001.<BR><BR>I
think it needs to be more like this. Here, I'm taking an educated
guess<BR>that you want your caller ID to appear on outgoing calls as 445789
followed<BR>by the last 2 digits of the extension number. If this is not
right, you will<BR>have to change it -- or explain exactly how to derive the
caller ID you want<BR>to appear on external phones, from the originating
internal extension, like I<BR>originally asked.<BR>
<DIV class=im><BR>exten =>
_90XXXXXXXXX,1,NoOp(${CALLERID(num)})<BR></DIV>exten =>
_90XXXXXXXXX,2,Set(outgoing_ident=445789${CALLERID(num):-2})<BR>exten =>
_90XXXXXXXXX,3,NoOp(${outgoing_ident})<BR>exten =>
_90XXXXXXXXX,4,Set(CALLERID(name)=${outgoing_ident})<BR>exten =>
_90XXXXXXXXX,5,AGI(agi://<A href="http://127.0.0.1:4577/call_log"
target=_blank>127.0.0.1:4577/call_log</A>)<BR>exten =>
_90XXXXXXXXX,6,Set(CALLERID(num)=${outgoing_ident})<BR>exten
=><BR>_90XXXXXXXXX,7,MixMonitor(/var/spool/asterisk/astrec/${TIMESTAMP}-${CALLERIDNUM}-${EXTEN}-${UNIQUEID}.gsm|<BR>av(0)V(0))<BR>exten
=>_90XXXXXXXXX,8,Dial(${TRUNK}/${EXTEN:1},,tTo)<BR>exten =>
_90XXXXXXXXX,9,Hangup<BR><BR>What this will do:<BR><BR>Stage 1: The
NoOp() will just write the CALLERID(num) to the console.
(This<BR>initially will be the originating extension number.)<BR>Stage
2: Creates a variable "outgoing_ident". This consists of the
string<BR>445789 followed by the last 2 digits of the originating extension
number.<BR>Stage 3: The NoOp() will write the value of ${outgoing_ident}
to the console.<BR>Stage 4: Sets CALLERID(name) to the value we just put
into ${outgoing_ident}.<BR>Stage 5: Calls logging AGI script.<BR>Stage
6: Sets CALLERID(num) to the value we just put into
${outgoing_ident}.<BR>This is most likely to be noticed.<BR>Stage 7:
Starts recording.<BR>Stage 8: Passes the dialled number, skipping
1 digit from the beginning, to a<BR>Dial() command.<BR>Stage 9: Hangs
up.<BR><BR>Modify stage 2 if necessary to suit exactly how you want your
outgoing ident<BR>to appear. You can take out the NoOp() statements and
renumber appropriately<BR>once it's working as you want it.<BR><BR>Note that
if the console seems to show you created the right ident but it<BR>doesn't
appear on phones when you dial out, then either the format is wrong<BR>or your
telco doesn't think you are authorised to use that ident; this is a<BR>matter
you will need to take up with your phone company.<BR><FONT
color=#888888><BR>--<BR></FONT>
<DIV>
<DIV></DIV>
<DIV class=h5>AJS<BR><BR>Answers come *after*
questions.<BR><BR>--<BR>_____________________________________________________________________<BR>--
Bandwidth and Colocation Provided by <A href="http://www.api-digital.com"
target=_blank>http://www.api-digital.com</A> --<BR>New to Asterisk? Join us
for a live introductory webinar every Thurs:<BR>
<A href="http://www.asterisk.org/hello"
target=_blank>http://www.asterisk.org/hello</A><BR><BR>asterisk-users mailing
list<BR>To UNSUBSCRIBE or update options visit:<BR> <A
href="http://lists.digium.com/mailman/listinfo/asterisk-users"
target=_blank>http://lists.digium.com/mailman/listinfo/asterisk-users</A><BR></DIV></DIV></BLOCKQUOTE></DIV><BR><BR
clear=all><BR>-- <BR><FONT face="Verdana, sans-serif"><FONT size=2><FONT
color=#000000>Best Regards, <BR><BR>Mahesh Katta</FONT><BR><FONT
color=#ff9900><B>BUZZ</B></FONT><FONT color=#000000><B>WORKS</B></FONT><FONT
color=#000000> Business Services Private Limited<BR></FONT><FONT
color=#999999>BANGALORE </FONT><FONT color=#000000>| </FONT><FONT
color=#999999>CHENNAI </FONT><FONT color=#808080>| </FONT><FONT
color=#999999>HYDERABAD </FONT><FONT color=#000000>| </FONT><FONT
color=#ff9900>MUMBAI| </FONT><FONT color=#999999>DELHI<BR></FONT><FONT
color=#000000>201, Crystal Tower, 75 Gundavali Cross Lane, Andheri Kurla Road,
Andheri (E) Mumbai 400069</FONT><FONT color=#666666><BR></FONT><FONT
color=#ff9900>GSM</FONT><FONT color=#000000> +91.97029.70779 | </FONT><FONT
color=#ff9900>Phone </FONT><FONT color=#000000>+91.22.4229.2634 | </FONT><FONT
color=#ff9900>Fax </FONT><FONT color=#000000>+91.22.4229.2634<BR></FONT><FONT
color=#ff9900>Web</FONT><FONT color=#000000> <A href="http://www.buzzworks.com/"
target=_blank>http://www.buzzworks.com<BR></A></FONT></FONT></FONT><BR></BODY><!--[object_id=#datavox.co.uk#]--><P><BR> If you have received this communication in error we would appreciate<BR>you advising us either by telephone or return of e-mail. The contents<BR>of this message, and any attachments, are the property of DataVox,<BR>and are intended for the confidential use of the named recipient only.<BR>If you are not the intended recipient, employee or agent responsible<BR>for delivery of this message to the intended recipient, take note that<BR>any dissemination, distribution or copying of this communication and<BR>its attachments is strictly prohibited, and may be subject to civil or<BR>criminal action for which you may be liable.<BR>Every effort has been made to ensure that this e-mail or any attachments<BR>are free from viruses. While the company has taken every reasonable<BR>precaution to minimise this risk, neither company, nor the sender can<BR>accept liability for any damage which you sustain as a result of viruses.<BR>It is recommended that you should carry out your own virus checks<BR>before opening any attachments. </P>
<P>Registered in England. No. 27459085.<BR><BR></P></HTML>