本文整理匯總了PHP中sms::execute_sms方法的典型用法代碼示例。如果您正苦於以下問題:PHP sms::execute_sms方法的具體用法?PHP sms::execute_sms怎麽用?PHP sms::execute_sms使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類sms
的用法示例。
在下文中一共展示了sms::execute_sms方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: date
//get data sms
$sql = "SELECT sms.notifikasi,sms.id ,ap.hp,ap.password,u.username,u.id as iduser\n\t\t\t\t\t\tFROM ak_notifikasi_sms sms\n\t\t\t\t\t\tJOIN ak_pegawai ap \n\t\t\t\t\t\tJOIN users u\n\t\t\t\t\t\tON ap.id_siswa = sms.id_siswa\n\t\t\t\t\t\tAND u.id_pengguna=ap.id\n\t\t\t\t\t\tWHERE date(waktu)='" . date('Y-m-d') . "'";
$q = mysql_query($sql);
echo $sql;
$apikey = '81f6cf2706d2302a33782a6126b16469';
//$nohp = '+6283867139945';
//$pesan = 'cek api';
$this->sms->key = '81f6cf2706d2302a33782a6126b16469';
$this->sms->phone = '2rajasms';
while ($hsl = mysql_fetch_assoc($q)) {
if (strlen($hsl['hp']) > 8 && strlen($hsl['hp']) < 15 && $hsl['notifikasi'] != '') {
//$encode=$hsl['notifikasi'].'. Pantau akademik putra/putri anda di https://studentbook.co/u/'.base64_encode($hsl['iduser']);
$encode = $hsl['notifikasi'];
echo '<pre>';
print_r($hsl['hp']);
echo '</pre>';
echo '<pre>';
print_r($encode);
echo '</pre>';
$this->sms->setTo($hsl['hp']);
$this->sms->setText($encode);
$sts = $this->sms->send();
mysql_query("DELETE FROM `ak_notifikasi_sms` WHERE id=" . $hsl['id'] . "");
//die();
}
}
}
}
$dom = new sms();
$dom->execute_sms();