你怎么在网址中包含&符号的亚行外壳上午开始? [英] How do you include ampersands in URLs for adb shell am start?
本文介绍了你怎么在网址中包含&符号的亚行外壳上午开始?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
使用
$ adb shell am start some://url
我可以启动使用活动管理器的URL。但是,如果我有多个URL参数,除了第一个参数被剥离出来。
I can launch URLs using activity manager. However if I include multiple URL parameters, all but the first parameter gets stripped out.
例如:
$ adb shell am start http://www.example.com?param1=1¶m2=2
返回:
$ Starting: Intent { act=android.intent.action.VIEW dat=http://www.example.com?param1=1 }
和param2的消失,任何东西之后符号被忽略。我不知道是否有用于与放一些编码/转义字符;这种意志prevent这一点。
and param2 disappears as anything after an ampersand gets ignored. I'm wondering if there's some encoding/escape character for the & that will prevent this.
推荐答案
使用转义字符 \
:
$ adb shell am start "http://www.example.com?param1=1\¶m2=2"
这篇关于你怎么在网址中包含&符号的亚行外壳上午开始?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文