I found out as a pointer to the session_request is included in
the callback call, I can add the needed mk structures in a custom header file and access the http header data in sr->body.data

It's not pretty, but it do work for my simple needs.

struct session_request *srp = (struct session_request *) sr;
printf("Data: \"%s\"\n", srp->body.data);

I'm planing to look into Duda in the future then I'm in need for more advanced functionality like websockets. Does it work as embedded library?

Regards,
Björn

On Wed, 28 Nov 2012, Eduardo Silva wrote:

On Wed, Nov 28, 2012 at 2:19 AM, nr <[email protected]> wrote:


If I do want to get the HTTP request hearder while in the callback
function, how do I do that?

In my program I do set a session cookie with unique session id number that
is included in every client request as a single line in the HTTP header.

Regards,
Bjön
_______________________________________________
Monkey mailing list
[email protected]
http://lists.monkey-project.com/listinfo/monkey


that is no supported yet in the Library version, if you are playing with
cookies and sessions i recommend you to take a look to the Duda framework:

 http://duda.io

there you have a few C pseudo-objects to handle sessions, cookies and
customize response headers:

 http://duda.io/api/session.html

if you want come to irc.freenode.net #monkey so we can give you further
assistance,

regards,

--
Eduardo Silva
http://edsiper.linuxchile.cl
http://www.monkey-project.com
_______________________________________________
Monkey mailing list
[email protected]
http://lists.monkey-project.com/listinfo/monkey

Reply via email to