You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modules-dev@httpd.apache.org by Himadri Sarkar <s....@gmail.com> on 2008/09/24 09:08:14 UTC

Apache Module + C Sockets

Hello,

I am new to apache module development and need some help.

I have a search application which runs on port 8100. My C Socket client
connects to this port, writes query to server, reads result from server and
displays it on the console as given in desired_output.txt.

Now I have written an apache module to do the same task (mod_helloworld.c).
But it displays the output in the format as given in current_output.html. In
this output every 4th character starting from first matches the desired
output and rest is some special character. I have tried reading output via
wide characters (wchar_t) too, but with same result. Is there any function
in apache module by which we can directly write wide characters to html or
is there some other solution to this problem. Any help in this regard will
be higly appreciated.

Regards

--
Himadri

Re: Apache Module + C Sockets

Posted by Himadri Sarkar <hi...@itbhu.ac.in>.
I am uploading files on the web Their links are

mod_helloworld.c : http://pastebin.com/pastebin.php?dl=m5ce68bac
current_output.html : http://pastebin.com/pastebin.php?dl=m6b834c8e
desired_output.html : http://pastebin.com/pastebin.php?dl=m3d795945

--
Himadri Sarkar

2008/9/24 Himadri Sarkar <s....@gmail.com>

> Hello,
>
> I am new to apache module development and need some help.
>
> I have a search application which runs on port 8100. My C Socket client
> connects to this port, writes query to server, reads result from server and
> displays it on the console as given in desired_output.txt.
>
> Now I have written an apache module to do the same task (mod_helloworld.c).
> But it displays the output in the format as given in current_output.html. In
> this output every 4th character starting from first matches the desired
> output and rest is some special character. I have tried reading output via
> wide characters (wchar_t) too, but with same result. Is there any function
> in apache module by which we can directly write wide characters to html or
> is there some other solution to this problem. Any help in this regard will
> be higly appreciated.
>
> Regards
>
> --
> Himadri
>

Re: Apache Module + C Sockets

Posted by Himadri Sarkar <s....@gmail.com>.
I am uploading files on the web Their links are

mod_helloworld.c : http://pastebin.com/pastebin.php?dl=m5ce68bac
current_output.html : http://pastebin.com/pastebin.php?dl=m6b834c8e
desired_output.html : http://pastebin.com/pastebin.php?dl=m3d795945

--
Himadri Sarkar

2008/9/24 Himadri Sarkar <s....@gmail.com>

> Hello,
>
> I am new to apache module development and need some help.
>
> I have a search application which runs on port 8100. My C Socket client
> connects to this port, writes query to server, reads result from server and
> displays it on the console as given in desired_output.txt.
>
> Now I have written an apache module to do the same task (mod_helloworld.c).
> But it displays the output in the format as given in current_output.html. In
> this output every 4th character starting from first matches the desired
> output and rest is some special character. I have tried reading output via
> wide characters (wchar_t) too, but with same result. Is there any function
> in apache module by which we can directly write wide characters to html or
> is there some other solution to this problem. Any help in this regard will
> be higly appreciated.
>
> Regards
>
> --
> Himadri
>