HTTPEncode

From Soldat Community Wiki
Revision as of 10:53, 15 August 2012 by Freeman (talk | contribs) (Created page with " ''function HTTPEncode(Source: string): string;'' '''Parameter Info:''' Source (String): String to be encoded. '''Description:''' This function will encode a string(...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
function HTTPEncode(Source: string): string;

Parameter Info:
 Source (String): String to be encoded.

Description:
 This function will encode a string(Source) to be safe for use in a URL.
NOTE: DO NOT ENCODE A COMPLETE URL! LIKE http://google.com/ ONLY THE PARAMETERS AFTER THE URL!

Examples

var
MyData: String
begin
    MyData := GetURL('http://www.domain.com/poo.php?var='+HTTPEncode('string$#with#wierd@chars?'));
end;


External Links