php 发送手机短信实例代码。
通过
ICQ 网关发送手机短信的 php 源程序
代码如下
:
<?
//###########################################################
//
// For questions and comments
// Roland (alias -=: Vlieg :=-)
// icq #78354631
// mail: vlieg@atoomnet.net
//
// NB: This script won't work on free hosting pages, because of the secure mode!
// NB: You must have registered your ICQ# at
//###########################################################
//****************************************************************\//Config:
$uin
="";
//your ICQ number
$passw
="";
//your ICQpassWord
$PRefix
="";
//sms prefix
$phonenumber
="";
//sms phone number
$message
= "Hello!";
//sms message
//****************************************************************\// EN: calculate
the content length
$contentlength
= ( 37+
strlen
(
$uin
)+
strlen
(
$passw
)
);
//****************************************************************\// Openen van
de inlogpagina
// EN: open loginpage
$htmlreply
="";
$post
="POST http:
//web.icq.com/karma/dologin/1,,,00.html HTTP/1.0
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/vnd.ms-Powerpoint,
application/vnd.ms-Excel, application/msword, */*
Referer: http:
//web.icq.com/sms/login/1,,,00.html
Accept-Language: nl
Content-Type: application/x-www-form-urlencoded
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 5.0; Windows 98; DigExt)
Host: web.icq.com
Content-Length: ".$contentlength."
Proxy-Connection: Keep-Alive
Pragma: no-cache