perlfetion.pl
在Ubuntu下编写了一个小脚本,存储手机号码和密码,实现别名发送。
代码: 全选
#/bin/bash
NUM="$1"
if [ -z "$1" ]; then
echo "$0 姓名或号码 消息"
exit 1
else
case "$NUM" in
myself) shift
perlfetion.pl 138XXXXXXXX password 138XXXXXXXX "$*"
;;
*) perlfetion.pl 138XXXXXXXX password "$*"
esac
fi
exit 0
代码: 全选
#/bin/bash
NUM="$1"
if [ -z "$1" ]; then
echo "$0 姓名或号码 消息"
exit 1
else
case "$NUM" in
myself) shift
MSG=$(echo "$*" | iconv -f gbk -t utf-8)
perlfetion.pl 138XXXXXXXX password 138XXXXXXXX ${MSG}
;;
*) perlfetion.pl 138XXXXXXXX password "$*"
esac
fi
exit 0
iconv: (标准输入):1:2: 无法转换
Retrieving the config xml...
Retrieving the SSIAPP URL...
Retrieving the SIPC Address...
Trying to get the fetion number of the current account...
Connecting to the SIPC via TCP socket...
Login OK
Send SMS succeed
转码不成功,请大家指教。