我是 USSD 的新手,但我已经使用 Kannel 1.5.4 发送消息很久了。我想使用 kannel 发送/接收 USSD 请求。我有相同的 smpp v5 帐户。如果有人通过配置文件帮助我,那就更好了。我的配置文件是:
#SMSC CONNECTIONS
group = smsc
smsc = smpp
smsc-id = USSD-ACC
host= 10.*.*.*
port= 1234
transceiver-mode=true
smsc-username = "USER"
smsc-password = "PWD"
system-type = ""
interface-version=34
source-addr-ton=5
source-addr-npi=0
dest-addr-ton=0
dest-addr-npi=1
max-pending-submits=10
wait-ack=600
wait-ack-expire=0x01
# SMSBOX SETUP
group = smsbox
bearerbox-host = localhost
sendsms-port = 12345
sendsms-chars = "0123456789 +-"
log-file = "/tmp/kannel_smsbox.log"
log-level = 3
# SERVICES
group = sms-service
keyword = default
get-url = "http://localhost/request.php?MNO=%p&SHORTCODE=%P&CONTENT=%a"
name="*123#" …Run Code Online (Sandbox Code Playgroud) 我在接收谷歌推送通知时面临以下问题.我从PHP提交以下通知,并在android GCMBaseIntentService中添加另一个标签data.notificationID以获取接收唯一ID.
$data = array(
'registration_id' => $deviceToken,
'collapse_key' => $collapseKey,
'data.message' => $messageText ,
'data.notificationID' => $yourKey
);
Run Code Online (Sandbox Code Playgroud)
通知正常,但notifyID值较旧,我先推了.它不是链接.但是我发送的data.message消息字符串是新来的.
php中的推送通知代码是:
<?php
$Key = "0000000";
$deviceToken = "sdfsjdfljsd";
$collapseKey = 1;
$messageText = "Hi welcome";
//$yourKey = 100;
$yourKey = 101;
$headers = array('Authorization:key=' . $Key);
$data = array(
'registration_id' => $deviceToken,
'collapse_key' => $collapseKey,
'data.message' => $messageText ,
'data.notificationID' => $yourKey
);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://android.googleapis.com/gcm/send");
if ($headers)
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, …Run Code Online (Sandbox Code Playgroud)