Skip to Content
Asterisk: The Future of Telephony
book

Asterisk: The Future of Telephony

by Jim Van Meggelen, Jared Smith, Leif Madsen
September 2005
Intermediate to advanced
408 pages
16h 20m
English
O'Reilly Media, Inc.
Content preview from Asterisk: The Future of Telephony

Name

StripMSD() — Strips the specified number of leading (most significant) digits from the current extension

Synopsis

    StripMSD(count)

Strips the leading count digits from the channel’s associated extension and continues processing at the next priority for the resulting extension. So, for example, if priority 1 of extension 5551212 is StripMSD(3), the first 3 digits will be stripped from 5551212 and the next step executed will be priority 2 of extension 1212. If you switch into an extension that has no priority n+1 (where n is the current priority), the PBX will treat it as though the user dialed an invalid extension.

Always returns 0.

This application is deprecated and has been replaced with the substring expression ${EXTEN: X : Y }.

               exten => 5551212,1,StripMSD(3)
    exten => 1212,2,SayDigits(${EXTEN})

    ; a better way of doing the same thing
    exten => 5551234,1,SayDigits(${EXTEN:3})

See Also

StripLSD(), README.variables, variable substring syntax

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Asterisk: The Future of Telephony, 2nd Edition

Asterisk: The Future of Telephony, 2nd Edition

Jim Van Meggelen, Jared Smith, Leif Madsen
What Employees Want Most in Uncertain Times

What Employees Want Most in Uncertain Times

Kristine W. Powers, Jessica B.B. Diaz

Publisher Resources

ISBN: 0596009623Supplemental ContentCatalog PageErrata