<div class="gmail_quote">On Wed, Sep 5, 2012 at 4:30 AM, David Klaverstyn <span dir="ltr">&lt;<a href="mailto:david@klaverstyn.com.au" target="_blank">david@klaverstyn.com.au</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div link="blue" vlink="purple" lang="EN-AU"><div><p class="MsoNormal">Hi All,<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">For some reason I can’t get this GotoIf statement to work.  Even if the name and number are the same it jumps to line 3.  I’ve tried with and without the quotes around each variable.<u></u><u></u></p>

<p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">exten =&gt; s,1,GotoIf($[&quot;${CALLERID(name)}&quot; = &quot;${CALLERID(num)}&quot;]?:3)<u></u><u></u></p><p class="MsoNormal">exten =&gt; s,2,NoOp(they are the Same)<u></u><u></u></p>

<p class="MsoNormal">exten =&gt; s,3,NoOp(they are different)<u></u><u></u></p><p class="MsoNormal"><u></u> <u></u></p><br></div></div><br></blockquote><div><br>You need to verify if the {CALLERID(num)} can actually match what your {CALLERID(name)} looks like.  More than likely, the (num) has some sort of brackets around it, such as &lt; &gt;, or perhaps it&#39;s starting with a +.  You can try to use the FILTER function on it, to strip away any additional characters that you don&#39;t want to see or try to match on.   <br>

<br><p class="MsoNormal">exten =&gt; s,1,GotoIf($[&quot;${CALLERID(name)}&quot; = &quot;${FILTER(0123456789,${CALLERID(num)}}&quot;]?:3)</p><p class="MsoNormal"><br></p><p class="MsoNormal"></p></div></div>That is, if you&#39;re just looking for numeric callerid.  If you also want to account for extra characters, you can add those to the first part of the filter.<br>

<br clear="all"><br>-- <br>Thanks,<br>--Warren Selby, dCAP<br><a href="http://www.selbytech.com" target="_blank">http://www.SelbyTech.com</a><br><br>