2

我从使用URLRequestActionScript 3 加载的 php 文件接收数据。当我跟踪时,data.toString()我得到以下输出。

systemResult=Invalid%0D%0A%3C%21%2D%2D%20Hosting24%20Analytics%20Code%20%2D%2D%3E%0D%0A%3Cscript%20type%3D%22text%2Fjavascript%22%20src%3D%22http%3A%2F%2Fstats%2Ehosting24%2Ecom%2Fcount%2Ephp%22%3E%3C%2Fscript%3E%0D%0A%3C%21%2D%2D%20End%20Of%20Analytics%20Code%20%2D%2D%3E%0D%0A

我想将其转换为正确的字符串。有没有办法在 AS3 中做到这一点。谢谢

4

1 回答 1

5

用于unescape()解码字符串。

所以unescape(data.toString())应该给你输出:

systemResult=Invalid

<!-- Hosting24 Analytics Code -->

<script type="text/javascript" src="http://stats.hosting24.com/count.php"></script>

<!-- End Of Analytics Code -->
于 2013-02-23T15:05:50.567 回答