Google Voice SMS Send interface PHP open source (2010.5 update) _php tutorial

Source: Internet
Author: User
1, support Mass
2, Chinese into pinyin send
If you need to bulk multi-account with a comma (,) delimited (86159..,86159.), the message content does not support Chinese, when you enter Chinese language, the system will automatically convert to pinyin (in order to distinguish between pinyin, pinyin initials), to ensure that the message can be sent normally (input "I am whirlwind" SMS content as "Wo Shi Xuan Feng ").
Copy CodeThe code is as follows:
/*
Tip: If you need to bulk multiple accounts with a comma (,) delimited (86159..,86159.), the message content does not support Chinese,
When you type in Chinese, the system will automatically convert to pinyin (in order to distinguish between pinyin, the first letter capitalized),
Ensure that messages are sent normally (input "I am Whirlwind" SMS Content "Wo Shi Xuan Feng")
PHP extension Required: Curl. Character encodings are GBK (consider pinyin conversion)
*/
Introducing Pinyin conversion requires a file
Include ("libs/pinyin.php");
Include "libs/googlevoice.class.php";
#设置google Voice account password
$username = "username@gmail.com";
$password = "password";
Accept numbers, multiple numbers, separated by "," (86159..,86159.)
$sendto = "8615900000000,8613400000000";
Message content
$message = "I am from heqee.com";
/*
Convert Chinese to Pinyin program to automatically identify Chinese to replace,
This feature is considered purely entertainment, and can be determined by the actual situation.
*/
$message = Zh2pinyin ($message);
Instantiation (required)
$sms = new Googlevoice ($username, $password);
return results
Text sent to 86134 ...
echo $sms->send ($sendto, $message);
?>

Source Library Package Download/201007/yuanma/googlevoiceapi.rar

http://www.bkjia.com/PHPjc/322217.html www.bkjia.com true http://www.bkjia.com/PHPjc/322217.html techarticle 1, Support mass 2, Chinese to pinyin send if you need to bulk multi-account with a comma (,) delimited (86159..,86159.), the message content does not support Chinese, when you enter Chinese, the system will ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.