By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,134 Members | 1,796 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,134 IT Pros & Developers. It's quick & easy.

CGI and C++: continual updates

P: n/a
Hi everyone

I'm programming CGI applications in C++. My latest prog has to request lots
of information from other servers which tend to be slow from time to time.

Apache waits until the whole CGI program has finished before it starts to
send the generated page to the browser.

In Perl it is possible to send data to the browser before the script has
completed. Does anyone know a way to do such things with c++ programs?
Simply flush cout doesn't help :(

During my search i came across the following page:
http://www.linuxjournal.com/article.php?sid=4386. This demonstrated way
doesn't seem to work on modern browsers, AFAIK this was never standard and
only implemented by older Netscape browsers.
Thanks for any help / links!
best regards

Flavio Tischhauser
Jul 22 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Flavio Tischhauser wrote:
Hi everyone

I'm programming CGI applications in C++. My latest prog has to request lots
of information from other servers which tend to be slow from time to time.

Apache waits until the whole CGI program has finished before it starts to
send the generated page to the browser.

In Perl it is possible to send data to the browser before the script has
completed. Does anyone know a way to do such things with c++ programs?
Simply flush cout doesn't help :(

During my search i came across the following page:
http://www.linuxjournal.com/article.php?sid=4386. This demonstrated way
doesn't seem to work on modern browsers, AFAIK this was never standard and
only implemented by older Netscape browsers.
Thanks for any help / links!


You'd probably get more help from an apache group. This question is off
topic in comp.lang.c++.

Two things you gound do:

a) do a manual http request (using telnet) and check to see if you're
actually not getting anything.

b) some html can't be rendered until it's all complete, so your browser
is getting the content, it is just is unable to display it.

Jul 22 '05 #2

P: n/a
Gianni Mariani <gi*******@mariani.ws> wrote in
news:bq********@dispatch.concentric.net:

You'd probably get more help from an apache group. This question is
off topic in comp.lang.c++.
Woops, sorry. On my way of learning CGI for C++ i got the most useful
answers from C++ boards and groups but my current problem really goes into
server specific problems.
Two things you gound do:

a) do a manual http request (using telnet) and check to see if you're
actually not getting anything.

b) some html can't be rendered until it's all complete, so your
browser is getting the content, it is just is unable to display it.


Thanks for your tips. I already tried that, my testprog only outputs simple
text which shouldn't be a problem.

Anyway, i'll try my luck in some Apache-Groups.

Have a nice weekend!
best regards

Flavio Tischhauser
Jul 22 '05 #3

P: n/a
Flavio Tischhauser wrote:
Hi everyone

I'm programming CGI applications in C++. My latest prog has to request lots
of information from other servers which tend to be slow from time to time.

Apache waits until the whole CGI program has finished before it starts to
send the generated page to the browser.

In Perl it is possible to send data to the browser before the script has
completed. Does anyone know a way to do such things with c++ programs?
You may try C++ CGI Toolkit from Softintegration, it is free and
runs across platform. However, this toolkit runs under C/C++ interpreter
Ch only. You can find more at

http://www.softintegration.com/products/toolkit/cgi/

Simply flush cout doesn't help :(

During my search i came across the following page:
http://www.linuxjournal.com/article.php?sid=4386. This demonstrated way
doesn't seem to work on modern browsers, AFAIK this was never standard and
only implemented by older Netscape browsers.
Thanks for any help / links!
best regards

Flavio Tischhauser


Jul 22 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.