Soporte & Consultoria

Soporte Remoto y Consultoria skype : ambiorixg12.
Nota no se brinda ningun tipo de consulta o soporte fuera del blog de forma gratuita

miércoles, 24 de febrero de 2016

Asterisk func if


Synopsis

Conditional: Returns the data following '?' if true else the data following ':'

Description

IF(<expr>?[<true>][:<false>])


Notes

  • *CLI> show function IF
  • Resides in func_logic.so module

Return value

Returns the resulting string.

Example

exten => s,1,Set(foo=${IF($[ ${x} = 7]?tval:fval)})

Another Example
exten => s,1,Set(mycid=${IF($[ ${CALLERID(num)} =102]?tval:fval)})
same=>n,Noop( value of ${mycid})


if caller id is  100 value of  ${mycid} is tval if  not is fval

No hay comentarios:

Publicar un comentario