🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.internet.web
4 messages
4 total messages Started by SubZero Thu, 07 Sep 2006 16:49
Javascript within C++
#701
Author: SubZero
Date: Thu, 07 Sep 2006 16:49
13 lines
1200 bytes
Hello,

We are producing javascript from within ICS web server/C++ and wonder if the 
following is possible with JS,

- Creating an upload meter for File POSTs with Javascript
- Making multi-socket uploads with different content-ranges (server-side 
will be coded by ourselves, we are looking for a solution to hack the 
browsers to send it)

Best Regards,

SZ 
Re: Javascript within C++
#708
Author: Colin B Maharaj
Date: Mon, 02 Oct 2006 22:27
46 lines
2372 bytes
In most web applications that has to eventually get a connection from a 
browser, the default behavior would be to get a connection send content 
and then disconnect.

Because of this it is almost impossible to have a true continuous status 
of any kind of activity.

A good option (but complex one) would be using AJAX. Asynchronous 
Javascript and XML. A simpler one would be to use an HTML  window of 
sorts and periodically update the state of the entire window (refresh) 
every 5 or more seconds.

To see a good example of this, go to dropload.com, create an account and 
send a file to someone (using their rules).

You will then see an upload screen that uploads and refreshes in the way 
I described.


Hope this helped...
Good luck!

Colin B Maharaj, Trinidad and Tobago.
--------------------------------------
C++ Builder, Javascript, XHTML, CSS Programmer at large.





SubZero wrote:
> Hello,
> 
> We are producing javascript from within ICS web server/C++ and wonder if the 
> following is possible with JS,
> 
> - Creating an upload meter for File POSTs with Javascript
> - Making multi-socket uploads with different content-ranges (server-side 
> will be coded by ourselves, we are looking for a solution to hack the 
> browsers to send it)
> 
> Best Regards,
> 
> SZ 
> 
> 
Re: Javascript within C++
#710
Author: Remy Lebeau (TeamB)
Date: Mon, 02 Oct 2006 23:40
14 lines
1359 bytes
"Colin B Maharaj" <noreply@myhost.com> wrote in message
news:45219233@newsgroups.borland.com...

> In most web applications that has to eventually get a connection from
> a browser, the default behavior would be to get a connection send
> content and then disconnect.

That is the default behavior in HTTP v1.0 and older.  The default behavior
in HTTP v1.1 is to keep the connection open between requests to the same
server.


Gambit
Re: Javascript within C++
#709
Author: Remy Lebeau (TeamB)
Date: Mon, 02 Oct 2006 23:45
26 lines
1893 bytes
"SubZero" <g_ates@hotmail.com> wrote in message
news:45004db8$1@newsgroups.borland.com...

> We are producing javascript from within ICS web server/C++ and
> wonder if the following is possible with JS,
>
> - Creating an upload meter for File POSTs with Javascript

Javascript alone cannot do that.  The closest you can get is to host the
status bar in a separate HTML frame, and have that page run a timer that
periodically sends a status request to the server to get new HTML for the
status bar.

> - Making multi-socket uploads with different content-ranges (server-side
> will be coded by ourselves, we are looking for a solution to hack the
> browsers to send it)

There is no way to make a browser do that.  There is nothing in HTML to tell
the browser to send a portion of a file.  It is an all-or-nothing operation.
To have better control over the connections, you would have to write a
custom Java/Flash applet or browser plugin to handle that on behalf of the
HTML page.


Gambit
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads