 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
None Guest
|
Posted: Fri Jan 23, 2004 1:15 pm Post subject: Http Problem |
|
|
Hi,
In my server a link to a binary (zip/exe) file when clicked shows an error message but when right clicked and 'Save target as' is chosen, the file downloads.
Is there a way to remove this problem? Also can i add support for more filetypes/extensions rather than just the txt/html and exe/zip etc ?
Thanks and Regards
|
|
| Back to top |
|
 |
None Guest
|
Posted: Fri Jan 23, 2004 7:11 pm Post subject: Re: Http Problem |
|
|
Hi,
| Quote: | What is the actual error message?
This file is hosted by <Brandname>, a <brandname>, and is not available for |
download. Please check out <brandname help> system for more information
about Remote Loading and our Remote Loading policy.
| Quote: | There is no difference between left- and right-clicking a link as far as
the
server is concerned, it will receive the same request for the file either
way. |
True, but the server i am talking about is the web server and merely
clicking on a link like :
http://click.this.link/getthisfile.zip produces the above error.
Right clicking (on the html page) starts the file-download dialog & a save
file requester dialog.
What do i have to do to have the file-download requester / curent download
manager automatically start downloading the file on a click instead of right
click --> save as target.
| Quote: | What are you using for your server in the first place? Are you coding the
HTTP protocol manually? Are you using a component? If a component, which
one exactly?
Not decided yet, probably Indy. Do i need to make a http Server to get what |
i want ? That is what i wanted to know.
Thaks and Regards
|
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Fri Jan 23, 2004 7:34 pm Post subject: Re: Http Problem |
|
|
"None" <none (AT) here (DOT) yet> wrote
| Quote: | In my server a link to a binary (zip/exe) file when clicked shows
an error message
|
What is the actual error message? What does your server code look like that
is processing the client's requests?
| Quote: | but when right clicked and 'Save target as' is chosen, the file downloads.
|
There is no difference between left- and right-clicking a link as far as the
server is concerned, it will receive the same request for the file either
way.
| Quote: | Also can i add support for more filetypes/extensions rather than just
the txt/html and exe/zip etc ?
|
What are you using for your server in the first place? Are you coding the
HTTP protocol manually? Are you using a component? If a component, which
one exactly?
Gambit
|
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Fri Jan 23, 2004 8:39 pm Post subject: Re: Http Problem |
|
|
"None" <none (AT) here (DOT) yert> wrote
| Quote: | This file is hosted by <Brandname>, a <brandname>, and is
not available for download. Please check out <brandname help
system for more information about Remote Loading and our
Remote Loading policy.
|
What kind of server are you using to begin with?
It doesn't matter, though, because the server has *no* way of knowing that
the user used the right mouse button instead of the left button. As I said,
the actual HTTP request that is generated by the client for downloading the
file is the same as far as the server is concerned. It should be able to
server the file properly regardless.
| Quote: | What do i have to do to have the file-download requester / curent
download manager automatically start downloading the file on a
click instead of right click --> save as target.
|
You are not listening. There is nothing to do, because it should already be
working to begin with. If it is not working, then the server itself is
faulty, or the client is sending a fauly request.
| Quote: | Not decided yet, probably Indy.
|
In other words, you haven't implemented any server at all yet? Yet you are
getting an error from a server already. So what EXACTLY are you CURRENTLY
using to get this error in the first place?
| Quote: | Do i need to make a http Server to get what i want ?
|
What exactly do you want to begin with? Are you making the server yourself,
or are you creating the client for someone else's server? More details,
please.
Gambit
|
|
| Back to top |
|
 |
None Guest
|
Posted: Sat Jan 24, 2004 10:00 pm Post subject: Re: Http Problem |
|
|
Hi,
| Quote: | It doesn't matter, though, because the server has *no* way of knowing that
the user used the right mouse button instead of the left button. As I
said,
the actual HTTP request that is generated by the client for downloading
the
file is the same as far as the server is concerned. It should be able to
server the file properly regardless.
|
I agree, but im talking about something different. In my web page, when a
link (to an exe file) is clicked, i would have expected a file download
dialog but i get that error msg. If i right-click the link (in MSIE) i get a
drop-down menu with the 'Save Target As...' option. This option brings about
the dialog.
What i want to know is what do i need to do to have a user click the link
and get the file to download via his preferred download manager ?
As a test try this page: http://sxb0.netfirms.com/html/download.htm
Click any of the links and see.
Thanks and regards
|
|
| Back to top |
|
 |
Ben Hochstrasser [FF] Guest
|
Posted: Sat Jan 24, 2004 11:58 pm Post subject: Re: Http Problem |
|
|
Remy Lebeau (TeamB) wrote:
| Quote: | In my web page, when a link (to an exe file) is clicked, i
would have expected a file download dialog
And you normally will get exactly that.
but i get that error msg.
Then the server is faulty.
|
Not necessarily - the browser might try to open the file directly (you can
select what file types to open and what to d/l) buf fails to do so, hence
the error message.
--
Ben
|
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Sun Jan 25, 2004 7:51 am Post subject: Re: Http Problem |
|
|
"Ben Hochstrasser [FF]" <bhoc@tiscali123^H^H^H.ch> wrote
| Quote: | Not necessarily - the browser might try to open the file directly
(you can select what file types to open and what to d/l) buf fails
to do so, hence the error message.
|
That is not the cause of the error. Regardless of whether the client is
going to open the file directly or save it first, it still has to REQUEST
THE FILE FROM THE SERVER in the first place before it can do anything with
the file data. Besides, the error in question is generated on the server
end regardless of the client's intentions for the file. It is not a
client-side error. If you look at the traffic data I quoted in my previous
message, you can see exactly what the browser is requesting and what the
server is returning. For whatever reason, the server is returning
redirection information when it shouldn't be. That means the server is
faulty, it is handling the client requests incorrectly, as both requests
should have resulted in the same file data being returned, but it actually
wasn't doing so.
Gambit
|
|
| Back to top |
|
 |
None Guest
|
Posted: Sun Jan 25, 2004 9:35 am Post subject: Re: Http Problem |
|
|
Hi,
| Quote: | However, just to put your mind at ease, I used Ethereal
(http://www.ethereal.com) to see exactly what data traffic is being
exchanged between IE and the server during both operations. Below are the
results. Now it is your responsibility to figure out why your server is
failing on them:
|
Thank you for the help. The results are what i was looking for to know what the problem was, just didnt know how to find it.
Regards
|
|
| Back to top |
|
 |
None Guest
|
Posted: Sun Jan 25, 2004 6:35 pm Post subject: Re: Http Problem |
|
|
Hi,
| Quote: | For whatever reason, the server is returning
redirection information when it shouldn't be. That means the server is
faulty, it is handling the client requests incorrectly, as both requests
should have resulted in the same file data being returned, but it actually
wasn't doing so.
|
So is there any thing that can be done to circumvent this problem? A server of sorts residing in the web that would redirect the requests from the links to the appropriate files and send them for download ?
Thanks and Regards
|
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Sun Jan 25, 2004 11:01 pm Post subject: Re: Http Problem |
|
|
"None" <none (AT) here (DOT) yet> wrote
| Quote: | So is there any thing that can be done to circumvent this problem?
|
Figure out why the server it not handling the requests correctly to begin
with. That would require you to debug the server itself, trace through its
handling of imcoming requests so that you can see when and why it decides to
return redirection information instead of actual file data. Considering
that in my earlier examples, the only differences between the two types of
requests were the "Accept" and "Referer" header values that the browser
submitted, the server is most likely mishandling at least one of those
header values. Both requests were requesting the same file, so both
requests should have received the same file data.
| Quote: | A server of sorts residing in the web that would redirect the
requests from the links to the appropriate files and send them
for download ?
|
You are missing the point. There is a *bug* in your "sxb0.netfirms.com"
server to begin with. Find the bug, and your problem will go away, and both
left- and right-click situations willl work correctly as expected.
Gambit
|
|
| Back to top |
|
 |
Ben Hochstrasser [FF] Guest
|
Posted: Mon Jan 26, 2004 7:52 am Post subject: Re: Http Problem |
|
|
None wrote:
| Quote: | But i cant do anything about the bug in the tripod server (the exe
files are located in tripod, same problem exists on pages hosted on
tripod servers). Thats simply out of my control. That is why i want to
override the server http requests and direct them to a bare bones
server hosted in tripod iteself.
|
AFAIK tripod doesn't want files to be "sucked" out-of-context (thus
avoiding their ad banners). This behaviour is intended. You are supposed to
load the "container html" page and only then right-click on the file to
download. Annonying for us users, good for tripod's ad department...
--
Ben
|
|
| Back to top |
|
 |
None Guest
|
Posted: Mon Jan 26, 2004 7:25 pm Post subject: Re: Http Problem |
|
|
But i cant do anything about the bug in the tripod server (the exe files are
located in tripod, same problem exists on pages hosted on tripod servers).
Thats simply out of my control. That is why i want to override the server
http requests and direct them to a bare bones server hosted in tripod
iteself.
Is this possible?
Thanks & Regards
| Quote: | You are missing the point. There is a *bug* in your "sxb0.netfirms.com"
server to begin with. Find the bug, and your problem will go away, and
both
left- and right-click situations willl work correctly as expected.
Gambit
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|