PHP ZWNG字符发送到电报

PHP ZWNG字符发送到电报,php,api,encoding,telegram,Php,Api,Encoding,Telegram,大家好,我有一个关于编码和电报的问题 当我将ZWNG零宽度空间从电报桌面发送到我的电报机器人时,如下所示: 它发送这个:u200b 类似这样的json: {"update_id":***, "message":{"message_id":***,"***":{"id":***,"first_name":"***","last_name":"***","username":"***"},"chat":{"id":***,"first_name":"***","last_name":"***",

大家好,我有一个关于编码和电报的问题

当我将ZWNG零宽度空间从电报桌面发送到我的电报机器人时,如下所示:

它发送这个:u200b 类似这样的json:

 {"update_id":***,
"message":{"message_id":***,"***":{"id":***,"first_name":"***","last_name":"***","username":"***"},"chat":{"id":***,"first_name":"***","last_name":"***","username":"***","type":"***"},"date":***,"text":"u2068"}}
现在我想用telegambot向我的用户发送这样的信息 问题是:如何用机器人发送这样的信息

我想从电报机器人发送一个ZWNG零宽度空间

Im使用此代码发送:

$curl = curl_init();
curl_setopt($curl,CURLOPT_URL,"https://api.telegram.org/bot***/SendMessage");
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS,
            "chat_id=230307754&parse_mode=Markdown&text=[".urldecode('200b')."](http://google.com)");
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
$json=curl_exec($curl);
$obj = json_decode($json);

看来你想寄一些东西,比如“می”​用你的机器人。 我建议您使用ZWSP(ZWSP)

您可以复制它或使用“Ctrl+Shift+2”或“Ctrl+-插入ZWSP”

例如:

<?php
$chatId = "********";
$botToken = "*********:****************************";
$website = "https://api.telegram.org/bot".$botToken;

sendMessage($chatId, "می​شود");exit;

function sendMessage ($chatId,$message) {
    $url = $GLOBALS[website]."/sendMessage?chat_id=".$chatId."&text=".urlencode($message);
    file_get_contents($url);
}

?>