[Asterisk-Users] Auto-dial from webpage

Andrew Thompson asteriskuser at aktzero.com
Tue Oct 21 07:24:11 MST 2003


----- Original Message ----- 
From: "WipeOut" <wipe_out at onetel.com>
To: <asterisk-users at lists.digium.com>
Sent: Tuesday, October 21, 2003 3:32 AM
Subject: Re: [Asterisk-Users] Auto-dial from webpage


> John Todd wrote:
> 
> >> I want to create a CGI that will allow me to make a call when a user
> >> clicks on a URL in a webpage. I believe I need to create a file in
> >> /var/spool/asterisk/outgoing that defines the number I want to call and
> >> the phone I want to connect it to but I see no way to define the phone
> >> number I want to dial in the /usr/src/asterisk/sample.call file I see
> >> mentioned in other posts. Is it possible to do what I want? Am I even
> >> looking in the right direction?
> >>
> >> elrod
> >>
> >> -- 
> >> Mark Elrod
> >> Vindicia, Inc.
> >> 2755 Campus Drive, Suite 240
> >> San Mateo, California 94403
> >>
> >> Email: elrod at vindicia.com
> >> Cell:  650-483-5763
> >> Main:  650-292-2409
> >> Fax:   650-345-1165
> >> Web:   http://www.vindicia.com
> >
> >
> > Mark -
> >   Hello!  To create a call to 14109850123 on an analog channel in 
> > group 2 and then connect it to the hypothetical extension 84 (which 
> > would map to 84,1,Dial(SIP/84) ) inside your network, here's the file 
> > you'd create in /var/spool/asterisk/outgoing.call:
> >
> > #
> > # Create the call on group 2 dial lines and set up
> > #  some re-try timers
> > #
> > Channel: Zap/g2/14109850123
> > MaxRetries: 2
> > RetryTime: 60
> > WaitTime: 30
> > #
> > # Assuming that your local extensions are kept in the
> > #  context called [extensions]
> > #
> > Context: extensions
> > Extension: 84
> > Priority: 1
> >
> >
> > I would strongly suggest that you create this file elsewhere, and copy 
> > it in after you're done creating it.  Asterisk is very aggressive in 
> > grabbing these files, and if you're still creating it when it grabs 
> > the file, you'll get errors, so best to create first and then copy in 
> > to the outgoing directory all at once.

Creating this file elsewhere would help in keeping track of whether or not your script created the file, and if it did so correctly.

Also, you would probably see results of these posts in your web log files, but having a datestamped dir of log entries couldn't hurt.

> >
> > JT
> > _______________________________________________
> > Asterisk-Users mailing list
> > Asterisk-Users at lists.digium.com
> > http://lists.digium.com/mailman/listinfo/asterisk-users
> >
>  From your example you would dial the outbound line and once connected 
> dial the internal extension.. does this not mean that the external 
> person would hear the phone rining when it was answered??
> 
> I do mine the other way around..
> 
> Channel: SIP/84
> WaitTime: 30
> Context: {the context that has your outbound dial string}
> Extension: 914109850123 ;9 added to number as if call was being placed 
> from a phone
> Priority: 1
> 
> This way the internal extension is dialed first and when answerd the 
> external number is dialed..
> 
> Later..
> 
> _______________________________________________
> Asterisk-Users mailing list
> Asterisk-Users at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-users
> 


-----
Andrew Thompson
NetResults, Inc.
(910) 215-9991 x301


More information about the asterisk-users mailing list