[asterisk-users] Idiot's Question

Eric "ManxPower" Wieling eric at fnords.org
Sat Jun 14 13:03:52 CDT 2008


Oddly "core show function SPRINTF" works on my 1.6.  SPRINTF function 
does not seem to be in 1.2 and I don't have any 1.4 systems.

Venefax wrote:
> Believe it or not, I cannot find online a single piece of documentation for
> the Asterisk function SPRINTF. This example does not work, for it changes
> the caller id.
> Set(CALLERID(num)=${SPRINTF(%010lld,0${CALLERID(num)})}),
> For instance, if the incoming caller id is 17864335989, I get 0684466805 out
> of that function, which is not intended one. To be precise, of the caller
> has less than 10 chars, I want to complete it with a string of '0's. If the
> caller id is nothing, or empty, I want to replace it with 10 zeroes. I guess
> I can figure it out if a link to the documentation of SPRINTF is provided.

-- 
Consulting for Asterisk, Polycom, Sangoma, Digium, Cisco, LAN, WAN, QoS, 
T-1, PRI, Frame Relay, Linux, and network design.  Based near 
Birmingham, AL.  Now accepting clients worldwide.



More information about the asterisk-users mailing list