[Freeswitch-users] sending of even from external to the lua script (onInput)
Yuriy Nasida
nasida at live.ru
Wed Sep 25 23:36:02 MSD 2013
Hi there!
My lua script has onInput function for listening of external events which I sends from other PHP script.
1) Lua function onInput(s, type, obj) if (type == "event") then freeswitch.consoleLog("warning", "get_info_and_play.lua: type = " .. type .. "\n"); ---------------- ---------------- endend-------------------
2) PHP<?php require_once('ESL.php'); $sock = new ESLconnection('MY_IP', '8021', 'Mypass'); $e = new ESLevent("CUSTOM",""); $e->addHeader("Result_od_sql_queue","1111111"); $sock->sendEvent($e);?>
I would like to catch such events but can not.
I set '/event plain all' in fs_cli and see that event received. But... Lua can not catch it.
May be I should add channel uuid of FS session to event I sent from PHP and this way lua script will able to get event?
Please advice.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20130925/5b117788/attachment.html
Join us at ClueCon 2013 Aug 6-8, 2013
More information about the FreeSWITCH-users
mailing list