2009/11/16 Daniel-Constantin Mierla miconda@gmail.com:
try this one:
$var(x) = "^sip:" + $avp(code) + "[0-9]+@";
if($ru =~ $var(x)) { ... }
Sorry Daniel, it was my fault. The AVP was not loaded at that point of the script. Now works fine. Only a question. Previously I had if(uri =~ ...) but I can't compare it with var(x). I know that $ru is a pseudo variable and "uri" is a core keyword. Can I change all my "if(uri =~ ...)" with "if($ru ~ ...)" without impact the actual configuration?
Cheers, Daniel
Thank you very much. Regards.