Problem is that the RFC definition for the URI doesn't specify the individual protocol scheme. So every protocol can specify it's own stuff.
Take the general sip URI: sip:user:password@host:port;uri-parameters?headers. User can be a telephone number with folowing definition: global-phone-number = "+" base-phone-number [isdn-subaddress] [post-dial] *(area-specifier / service-provider / future-extension) Or local-phone-number = 1*(phonedigit / dtmf-digit / pause-character) [isdn-subaddress] [post-dial] area-specifier *(area-specifier / service-provider / future-extension) This definitely will require custom processing. Also both uri-parameters and headers are name=value pairs. The first are separated by ";" and the second by "&"... I'm afraid a universal URI decoder isn't possible. Ludo -----Message d'origine----- De : fpc-pascal-boun...@lists.freepascal.org [mailto:fpc-pascal-boun...@lists.freepascal.org] De la part de michael.vancann...@wisa.be Envoyé : mercredi 18 mai 2011 16:14 À : FPC-Pascal users discussions Objet : Re: [fpc-pascal] Re: URIParser On Wed, 18 May 2011, ik wrote: > On Wed, May 18, 2011 at 16:49, <michael.vancann...@wisa.be> wrote: >> So, how to distinguish between the two ? >> >> sip:mysec...@mydomain.com >> >> Is "sip" the protocol or the user name for a HTTP address ? >> > > sip is the protocol, mysecrect is the user name > > sip::mysecr...@mydomain.com > > according to the RFC is the proper way to have > 1. Protocol > 2. Empty user name > 3. Password > 4. Domain I will check the implementation. As far as I know, it was never meant to be RFC compliant, but we can change that of course. Michael. _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal