Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Fri Mar 29, 2024 12:28 am
VoIP Billing solution


All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Sip Friends Internal Calling NAME Caller ID FIXED
PostPosted: Wed Aug 20, 2008 2:13 pm 
Offline

Joined: Sat Aug 16, 2008 5:15 am
Posts: 10
hey guys...

I have been reading about PHP and AGI,

is there a way that I can send both Callerid NUM and CallerID Name to the the destination number?

Thanks


Last edited by za3toor on Sat Aug 30, 2008 1:09 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 20, 2008 2:25 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
If you have auto_setcallerid = YES and cid_sanitize = NO, then you should find the Caller ID presented by your SIP client is passed through unmodified.
If you want to impose both a textual and numeric Caller ID I'm pretty sure you'll have to modify the code in A2B which deals with this.


Top
 Profile  
 
 Post subject: Fixed
PostPosted: Sat Aug 30, 2008 1:08 am 
Offline

Joined: Sat Aug 16, 2008 5:15 am
Posts: 10
here is the fix to display both Last Name, First Name, and number



in file Class.A2billing.php

change this line

Code:
$agi->set_callerid($this->useralias);


to


Code:

         $QUERY = "SELECT firstname, lastname FROM cc_card WHERE useralias='".$this->useralias."'";         
         $this -> debug( VERBOSE | WRITELOG, $agi, __FILE__, __LINE__, $QUERY);                              
         $result = $this -> instance_table -> SQLExec ($this->DBHandle, $QUERY);
         $this -> debug( VERBOSE | WRITELOG, $agi, __FILE__, __LINE__, $result);
         $firstname=$result[0][0];
         $lastname=$result[0][1];
         $newcallerid = "\"$lastname". " $firstname  <$this->useralias>\"";
         $agi->set_callerid($newcallerid);



Thanks for all those that helped

za3toor


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 
VoIP Billing solution


All times are UTC


Who is online

Users browsing this forum: No registered users and 10 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group