问问题
2016 次
1 回答
0
In C# you have the System.Web.HttpUtility.JavaScriptStringEncode() call available that will prepend single quotes with a backslash.
http://msdn.microsoft.com/en-us/library/system.web.httputility.javascriptstringencode.aspx
From the URL above:
This method encodes strings. For instance, single quotation marks and double quotation marks are included as \' and \" in the encoded string.
于 2012-10-12T15:02:24.643 回答