Article View: borland.public.cppbuilder.internet.web
Article #540Re. URLEncode
From: Elmar Baumann
Date: Mon, 13 Mar 2006 16:43
Date: Mon, 13 Mar 2006 16:43
42 lines
1745 bytes
1745 bytes
>Hamid wrote in Article <4415301a$1@newsgroups.borland.com>
>with Subject: URLEncode, on 13.03.2006 08:40:58
>
>
>
>How can I encode a uri using a TIdURI class? The C++Builder version of the URLEncode function wants a Metaclass object that I can not understand what it is?
Hello,
AnsiString url,WebUrl,html;
TMetaClass *cl;
TIdURI *uri;
WebUrl = "http://www.test.com"; // your url to encode
url = uri->URLEncode(cl,Weburl);
try
{
html = IdHTTP1->Get(url);
}
catch (Exception &exception)
{
// do something if an exception is raised
}
Best Regards
Elmar Baumann
------------------------------------------------------------------------------
Indy9 NNTP Internet News Reader/Writer, E. Baumann Software 2005
Portions of this Software are Copyright (c) 1993 - 2005,
Chad Z. Hower (Kudzu) and the Indy Pit Crew
<http://www.IndyProject.org/>
Technical Details
Message-ID:
<4415a141@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news4.google.com!news.glorb.com!newsfeeder.wxs.nl!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<4415301a$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: feeec,9d159ea63ec27d7 X-Google-Attributes: gidfeeec,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Elmar Baumann" <elmar-nospam@anywhere.net> Subject: Re. URLEncode Newsgroups: borland.public.cppbuilder.internet.web Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Organization: Baumann Software NNTP References: <4415301a$1@newsgroups.borland.com> Date: Mon, 13 Mar 2006 17:43:44 +0100 X-Newsreader: BaumannSoftware NNTP NNTP-Posting-Host: 84.60.0.205 Message-ID: <4415a141@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1142268225 84.60.0.205 (13 Mar 2006 08:43:45 -0700) Lines: 43 Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news4.google.com!news.glorb.com!newsfeeder.wxs.nl!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail