🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.internet.web
5 messages
5 total messages Started by Shao Chin Sat, 02 Jun 2007 20:37
TIdHTTP component
#194
Author: Shao Chin
Date: Sat, 02 Jun 2007 20:37
7 lines
1311 bytes
Hi, I'm trying to write an applicatoin that downloads a web page given a URL. I know there is an Indy component called TIdHTTP that can do this in two lines of code:
   TFileStream *fs = new TFileStream(filename, fmCreate);
   IdHTTP->DoRequest(hmGet,url,NULL,fs);
Which will download a page into a file. However, I can't find this component anywhere on the internet (all download sites are out of date). I'm running BC++ Builder 5.0 Professional. Does anyone how to do this in BC++ 5.0 without this Indy component?
THanks!
Shao
Re: TIdHTTP component
#195
Author: Remy Lebeau (TeamB)
Date: Mon, 04 Jun 2007 20:11
25 lines
1570 bytes
"Shao Chin" <fafy_99@yahoo.com> wrote in message
news:4661d4ee$1@newsgroups.borland.com...

>    IdHTTP->DoRequest(hmGet,url,NULL,fs);

Use the Get() method instead of the DoRequest() method directly:

    IdHTTP->Get(url, fs);

> However, I can't find this component anywhere on the internet

Indy ships preinstalled with BCB 6+.  Otherwise, download it from the
official Indy website: http://www.indyproject.org)

> Does anyone how to do this in BC++ 5.0 without this Indy
> component?

You can use Microsoft's WinInet or WinHTTP APIs.  Otherwise, you have
to write your own HTTP code from scratch using TClientSocket or
WinSock API calls directly, or use another third-party
component/library, such as ICS or Synapse.


Gambit
Re: TIdHTTP component
#197
Author: shao chin
Date: Thu, 07 Jun 2007 05:27
37 lines
1855 bytes
Thanks!
It turns out that the TNMHTTP component in BC++ 5.0 can do the same thing, using NMHTTP1->Get(url).
By the way, http://www.indyproject.org doesn't work any more. All downloads have been removed.

Shao


"Remy Lebeau \(TeamB\)" <no.spam@no.spam.com> wrote:
>
>"Shao Chin" <fafy_99@yahoo.com> wrote in message
>news:4661d4ee$1@newsgroups.borland.com...
>
>>    IdHTTP->DoRequest(hmGet,url,NULL,fs);
>
>Use the Get() method instead of the DoRequest() method directly:
>
>    IdHTTP->Get(url, fs);
>
>> However, I can't find this component anywhere on the internet
>
>Indy ships preinstalled with BCB 6+.  Otherwise, download it from the
>official Indy website: http://www.indyproject.org)
>
>> Does anyone how to do this in BC++ 5.0 without this Indy
>> component?
>
>You can use Microsoft's WinInet or WinHTTP APIs.  Otherwise, you have
>to write your own HTTP code from scratch using TClientSocket or
>WinSock API calls directly, or use another third-party
>component/library, such as ICS or Synapse.
>
>
>Gambit
>
>
>
Re: TIdHTTP component
#198
Author: Remy Lebeau (TeamB)
Date: Fri, 08 Jun 2007 20:03
20 lines
1549 bytes
"shao chin" <fafy_99@yahoo.com> wrote in message
news:46679732$1@newsgroups.borland.com...

> It turns out that the TNMHTTP component in BC++ 5.0 can
> do the same thing, using NMHTTP1->Get(url).

The Netmaster components are notoriously buggy and unreliable.  That's
why Borland doesn't bundle them anymore.

> By the way, http://www.indyproject.org doesn't work any more.

Works fine for me.

> All downloads have been removed.

No, they have not.  I just tried it and everything downloaded fine.


Gambit
Re: TIdHTTP component
#218
Author: Mark Jacobs
Date: Tue, 17 Jul 2007 10:07
18 lines
1634 bytes
"Remy Lebeau (TeamB)" <no.spam@no.spam.com> wrote in message 
news:4669b667$1@newsgroups.borland.com...
>
> "shao chin" <fafy_99@yahoo.com> wrote in message
> news:46679732$1@newsgroups.borland.com...
>> By the way, http://www.indyproject.org doesn't work any more.
>
> Works fine for me.
>
>> All downloads have been removed.
>
> No, they have not.  I just tried it and everything downloaded fine.

Works fine for me too. What planet is this guy on?
-- 
Mark Jacobs
DK Computing
http://www.dkcomputing.co.uk
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