<p>Good idea Leif. </p>
<p><blockquote type="cite">On 2010-03-19 10:16 AM, "Leif Madsen" <<a href="mailto:leif.madsen@asteriskdocs.org">leif.madsen@asteriskdocs.org</a>> wrote:<br><br><p><font color="#500050">Zeeshan Zakaria wrote:<br>
> You'll have to type them all in manually. Or do what I did several <br>> times...</font></p>Using the script approach, you can generate many extensions with an #exec in<br>
sip.conf which will then trigger a script (such as via PHP or whatever) and<br>
whatever information you output via STDOUT will then be used when chan_sip is<br>
loaded.<br>
<br>
Using a template will make what you need to output much easier.<br>
<br>
Something like...<br>
<br>
#!/usr/bin/php<br>
<?php<br>
$x=1000;<br>
while ($x < 2000) {<br>
echo "[$x](my_template)\n";<br>
$x++;<br>
};<br>
?><br>
<br>
<br>
Then define in sip.conf [my_template](!)<br>
<br>
Then fill in whatever information you need for the extensions.<br>
<br>
Then you can use<br>
#exec make_extensions.php<br>
<br>
Leif.<br>
<font color="#888888"><br>
--<br>
</font><p><font color="#500050">_____________________________________________________________________<br>-- Bandwidth and Colocation Pr...</font></p></blockquote></p>