[Freeswitch-users] PHP ESL Custom Events Event-Name sent twice

Anthony Minessale anthony.minessale at gmail.com
Tue Jan 17 02:26:54 MSK 2012


I am not seeing that, perhaps you are on an older version?

On Mon, Jan 16, 2012 at 9:39 AM, Gerald Weber <gerald.weber at besharp.at>wrote:

> Hello,****
>
> ** **
>
> i’m trying to send custom events using PHP ESL Library.****
>
> (running FreeSWITCH Version 1.0.head (git-c37c029 2012-01-11 21-35-19
> -0600))****
>
> My PHP Code:****
>
> ** **
>
> <?php****
>
>         require_once('ESL.php');****
>
> ** **
>
>         $sock = new ESLconnection('192.168.20.73', '8021', 'ClueCon');****
>
> ** **
>
>         $e = new ESLevent("CUSTOM","CONFIG::AGENT_LIST");****
>
>         $e->addHeader("Agents","2022");****
>
> ** **
>
>         $sock->sendEvent($e);****
>
> ?>****
>
> ** **
>
> When I connect to fs using telnet and run the php script from another
> xterm, I can see the following output:****
>
> ** **
>
> Content-Length: 657****
>
> Content-Type: text/event-json****
>
> ** **
>
> {****
>
>         "Event-Subclass":       "CONFIG::AGENT_LIST",****
>
>         "Event-Name":   "SOCKET_DATA",****
>
>         "Core-UUID":    "b3ac8858-4019-11e1-910a-9b04baf8e5ea",****
>
>         "FreeSWITCH-Hostname":  "freeswitch.local",****
>
>         "FreeSWITCH-Switchname":        "freeswitch.local",****
>
>         "FreeSWITCH-IPv4":      "192.168.20.73",****
>
>         "FreeSWITCH-IPv6":      "::1",****
>
>         "Event-Date-Local":     "2012-01-16 15:20:23",****
>
>         "Event-Date-GMT":       "Mon, 16 Jan 2012 14:20:23 GMT",****
>
>         "Event-Date-Timestamp": "1326723623776184",****
>
>         "Event-Calling-File":   "mod_event_socket.c",****
>
>         "Event-Calling-Function":       "read_packet",****
>
>         "Event-Calling-Line-Number":    "1188",****
>
>         "Command":      "sendevent CUSTOM",****
>
>         "Event-Name":   "CUSTOM",****
>
>         "Agents":       "2022",****
>
>         "ZMQ-Msg-Cnt":  "3508"****
>
> }****
>
> ** **
>
> Looks ok, but i don’t get why  “Event-Name” is sent twice.****
>
> Shouldn’t there be an Event-Name: CUSTOM only ?****
>
> Is there a way to avoid this or am i missing something ?****
>
> ** **
>
> thx & regards,****
>
> gw****
>
> ** **
>
> ** **
>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> 
> 
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://wiki.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>


-- 
Anthony Minessale II

FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/
Twitter: http://twitter.com/FreeSWITCH_wire

AIM: anthm
MSN:anthony_minessale at hotmail.com
GTALK/JABBER/PAYPAL:anthony.minessale at gmail.com
IRC: irc.freenode.net #freeswitch

FreeSWITCH Developer Conference
sip:888 at conference.freeswitch.org
googletalk:conf+888 at conference.freeswitch.org
pstn:+19193869900
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20120116/cff85e3e/attachment-0001.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list