public.xml:I've two registered users 3333 and 4444. when i use action "send" the message is forwarded, but when i use my script with event fire it's not...what am i missing?Hi,I'm using Linphone to test mod_sms on smart phones, the chat messages aren't being forwarded to the second user.
<?xml version="1.0" encoding="utf-8"?>
<include>
<context name="public">
<extension name="public">
<condition field="to" expression="^(.*)$">
<action application="lua" data="handle_chat.lua"/>
<action application="reply" data="Hello, you said: ${_body}"/>
<!--action application="send"/-->
</condition>
</extension>
</context>
</include>
handle_chat.lualocal body = message:getBody();
local from = message:getHeader("from");
local to = message:getHeader("to");
freeswitch.consoleLog("info", message:getHeader("from"));
freeswitch.consoleLog("info", message:getHeader("to"));
freeswitch.consoleLog("info", message:serialize());
freeswitch.consoleLog("info", message:getBody() .. "\n");
local event = freeswitch.Event("CUSTOM", "SMS::SEND_MESSAGE");
event:addHeader("proto", "sip");
event:addHeader("dest_proto", "sip");
event:addHeader("from", "sip:" .. from);
event:addHeader("from_full", "sip:" .. from);
event:addHeader("to", to);
event:addHeader("type", "text/html");
event:addHeader("replying", "true");
event:addBody("Hello from Seven Du! Have funnnnnnn!");
freeswitch.consoleLog("info", event:serialize());
event:fire();Thanks,Snabel
_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com
Official FreeSWITCH Sites
http://www.freeswitch.org
http://confluence.freeswitch.org
http://www.cluecon.com
FreeSWITCH-powered IP PBX: The CudaTel Communication Server
http://www.cudatel.com
FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org