Article View: borland.public.cppbuilder.internet.web
Article #1261Re: AResponseInfo->Referer question
From: Ulli
Date: Mon, 04 Apr 2005 15:25
Date: Mon, 04 Apr 2005 15:25
46 lines
2093 bytes
2093 bytes
Ok thanks I thought there is some kind of parser in the Indie componant
for that anyway.
Ulli
Am Mon, 04 Apr 2005 10:20:34 +0200 schrieb Hans Galema
<notused@notused.nl>:
> Ulli wrote:
>
>> First I wanted to have a Keywoard to know that the following is a
>> control string, but I think this solution will be o.k. too - or better
>> ;)
>
> <a href="Site_1.html?command=switch&Light_1=on">Light 1 on</a>
>
>> Just one other question, ist there a more elegant way to split
>> parameters at the "=" char than with .Pos amd .SubString
>
> If there is only one key=value pair then that would be ok. You would
> not even need to decode then as you could simply check:
>
> if ( Pos ( URL, "Light_1=on" ) )
> {
> //switch light 1 on
> }
>
> if ( Pos ( URL, "Light_1=off" ) )
> {
> //switch light 1 off
> }
>
> You could even do that when you have more key=value pairs.
>
> Otrherwise have a look at TStringList. CommaText and Names and Values
> properties. Please read the help for that.
>
> Hans.
Technical Details
Message-ID:
<opsoprskcvgmwg2m@localhost>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<opsoh67weogmwg2m@localhost> <424c50c6$1@newsgroups.borland.com> <opsojsglxqgmwg2m@localhost> <424d61f9@newsgroups.borland.com> <opsoo6ljd2gmwg2m@localhost> <4250f95a$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: feeec,4b33aa1f27c59276 X-Google-Attributes: gidfeeec,public X-Google-Language: ENGLISH,ASCII-7-bit Newsgroups: borland.public.cppbuilder.internet.web Subject: Re: AResponseInfo->Referer question References: <opsoh67weogmwg2m@localhost> <424c50c6$1@newsgroups.borland.com> <opsojsglxqgmwg2m@localhost> <424d61f9@newsgroups.borland.com> <opsoo6ljd2gmwg2m@localhost> <4250f95a$1@newsgroups.borland.com> Message-ID: <opsoprskcvgmwg2m@localhost> From: Ulli Content-Type: text/plain; format=flowed; charset=iso-8859-15 MIME-Version: 1.0 Content-Transfer-Encoding: Quoted-Printable Date: Mon, 04 Apr 2005 17:25:22 +0200 User-Agent: Opera7.23/Win32 M2 build 3227 NNTP-Posting-Host: 84.175.129.23 X-Trace: newsgroups.borland.com 1112628321 84.175.129.23 (4 Apr 2005 08:25:21 -0800) Lines: 47 Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail