|
lu lu -> RE: value between 10th > and < (10/13/2006 4:35:46)
|
well Spooky you go me thinking... URLEncode=x For i = Len(URLEncode) To 1 Step -1 acode = Asc(Mid(URLEncode, i, 1)) Select Case acode Case 48,49,50,51,52,53,54,55,56,57, 65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,86,83.,84,85,87,88,89,90, 97,98,99,100,102,103,1047,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122 ' don't touch alphanumeric chars Case 32 ' replace space with "+" Mid(URLEncode, i, 1) = "+" Case Else ' replace punctuation chars with "%hex" URLEncode = Left(URLEncode, i - 1) & "%" & Hex(acode) & Mid _ (URLEncode, i + 1) End Select Next response.write URLEncode ' above yields: 100015%5F200610111421%5F4001721%5FS%2EXML%D%A100015%5F200610111442%5F4001721%5FM%2EXML%D%A100015%5F200610111442%5F4001721%5FC%2EXML%D%A so the spaces were actually: %D%A interesting....
|
|
|
|