V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
nothing2
V2EX  ›  问与答

电报 api sendMessage 方法推送带“&”链接问题

  •  
  •   nothing2 · May 29, 2022 · 934 views
    This topic created in 1433 days ago, the information mentioned may be changed or developed.

    通过 tg api 之 sendMessage 方法,推送带“&”链接,如 https://example.com/show?id=123&userid=456 ,推送后“&userid=456”被丢弃。应如何保护完整链接?

    ochatokori
        1
    ochatokori  
       May 29, 2022 via Android
    encodeURIComponent ?
    ik
        2
    ik  
       May 29, 2022 via iPhone
    用的 shell? 完整 url 用引号包起来
    nothing2
        3
    nothing2  
    OP
       May 29, 2022
    补充一下,为 php 代码,用单引号、双引号都不行
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1186 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 17:20 · PVG 01:20 · LAX 10:20 · JFK 13:20
    ♥ Do have faith in what you're doing.