Javascript 当&;符号位于python调用的js函数的参数中
我一直在使用python的裸.toolshed.shell库来启动一个带有给定参数的js脚本。 问题是,例如,当参数中有“&”时,js只获取该符号前面的内容 Python: Js: CMD显示了什么:Javascript 当&;符号位于python调用的js函数的参数中,javascript,python,naked-objects,Javascript,Python,Naked Objects,我一直在使用python的裸.toolshed.shell库来启动一个带有给定参数的js脚本。 问题是,例如,当参数中有“&”时,js只获取该符号前面的内容 Python: Js: CMD显示了什么: example_of_a_link.com/width=640 因此&而后面的内容丢失了,我如何修复它呢?您可以通过传递以下内容来逃避& link.replace('&', '^&') …执行_js() example_of_a_link.com/width=640 link
example_of_a_link.com/width=640
因此&而后面的内容丢失了,我如何修复它呢?您可以通过传递以下内容来逃避
&
link.replace('&', '^&')
…执行_js()
example_of_a_link.com/width=640
link.replace('&', '^&')