Book Image

Elastix Unified Communications Server Cookbook

Book Image

Elastix Unified Communications Server Cookbook

Overview of this book

Table of Contents (24 chapters)
Elastix Unified Communications Server Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Description and Use of the Most Well-known FreePBX Modules
Addon Market Module
Asterisk Essential Commands
Asterisk Gateway Interface Programming
Helpful Linux Commands
Index

Controlling outbound calls by using patterns


Let us imagine that our analog lines have a special price for long-distance calls, but our digital E1 lines do not, and that all outbound calls must be dialed with 9 as an outbound prefix.

How to do it…

  1. Modify the current outbound dialing prefix 9.

  2. Substitute the character . by the number of digits for all calls, except long-distance calls. For our example, local calls use 7 digits, mobile calls use 10, and long-distance calls use 11 digits. In other words, the current outbound prefix with 9 will be as shown in the following image:

  3. Add a second outbound route named 9_Long_Distance.

  4. In the dialing patterns, we enter 9 in the prefix box and XXXXXXXXXXX (11 digits) in the match pattern field.

  5. Select the analog trunk in the Trunks section. The next image shows the result of these steps: