简单的问题 - 如何将此VBScript字符串转换为PHP字符串 [英] Simple question - How to convert this VBScript string to a PHP string

查看:60
本文介绍了简单的问题 - 如何将此VBScript字符串转换为PHP字符串的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

这是我要转换为PHP的VBScript:



Hello,
Here is the VBScript I want to convert to PHP:

Dim buffer = New String("")
buffer = buffer &("<Section name=""GLOBAL"" >" )





我知道双重双引号是为了逃避所以我在PHP中尝试反斜杠而不是双重双引号。





I know double double quotes are to escape so I tried backslash in PHP instead of double double quotes.

$buffer .= '("<Section name=\"GLOBAL\" >" )';





PHP输出为:( )



请帮忙。谢谢大家!



The PHP output is : ("" )

Please help. Thanks everyone !

推荐答案

buffer。='(< Section name = \GLOBAL \>)';
buffer .= '("<Section name=\"GLOBAL\" >" )';





PHP输出为:()



请帮助。谢谢大家!



The PHP output is : ("" )

Please help. Thanks everyone !


这是因为您的输出正在被解析。毕竟这是HTML。这就是您要找的:

http://php.net/manual/ en / function.htmlentities.php [ ^ ]
It's because your output is being parsed. It's html after all. This is what you are looking for:
http://php.net/manual/en/function.htmlentities.php[^]


见这里:

http ://forums.codecharge.com/posts.php?post_id = 84257 [ ^ ]


这篇关于简单的问题 - 如何将此VBScript字符串转换为PHP字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆