French and Other Language Characters – Classic ASPPublished: May 13, 2014 01:22:05
Physical Link: French and Other Language Characters – Classic ASP
Recently working with PayPal and Classic ASP I stumbled unto a problem where French characters were being encoded and displayed as unreadable text. It turns out that PayPal returns the result to you using UTF-8. In C# this would be an easy fix. Language characters can be tough in classic ASP. I had searched for quite a while until I found the following code:
Set JSEngine = CreateObject("MSScriptControl.ScriptControl")
JSEngine.Language = "JScript"
sConvert = Replace(sConvert, "+", " ")
URLDecode = JSEngine.CodeObject.decodeURIComponent(sConvert)
This solved my issue, but it took forever to find the solution. I hope this can save someone else time.
Contact me if you have questions integrating ASP with PayPal.
The post French and Other Language Characters – Classic ASP appeared first on Software Developer In London.
Author: Andrew Pallant
Categories: ASP, Developement, How To, Visual Basic, Classic ASP, French, Language Characters, PayPal, UTF-8