thomasdilts / sms_worshiphhn_ip1
这是一个使用sms供应商https://ip1sms.com为worshiphhn项目提供的SMS系统。
v1.0.4-stable
2019-09-02 14:31 UTC
Requires
- php: >=7.0.0
- thomasdilts/sms_worshiphhn: *
This package is auto-updated.
Last update: 2024-09-29 05:42:23 UTC
README
这是一个使用sms供应商https://ip1sms.com为WorshipHHN项目提供的SMS消息系统。该程序必须是thomasdilts/sms_worshiphhn项目中找到的文件Sms.php的子类,以便WorshipHHN可以使用它。
Rest(ful) API
短信消息供应商https://ip1sms.com使用Rest(ful) API来进行短信消息。这与许多其他短信消息系统不同,因为这种方法仅使用从供应商处“拉取”消息/回复的状态。在许多其他短信消息系统中,您需要提供供应商可以调用的网址,以提供消息状态的变化。我更喜欢“拉取”技术,因为它在数据完整性和防止黑客攻击方面都更加安全。
以下表格是此程序使用的https://ip1sms.com公开的Rest(ful) API
添加到WorshipHHN
要将此添加到WorshipHHN项目,您需要编辑WorshipHHN中的以下文件 _protected/config/web.php
'components' => [ ... 'SmsMessaging' => [ 'class' => 'thomasdilts\sms_worshiphhn_ip1\SmsForIp1', 'account' => 'YOUR_ACCOUNT', 'password' => 'YOUR_PASSWORD', 'apiUrl' => 'api.ip1sms.com', 'messageFrom' => 'FROM_NAME_OR_PHONE_NUMBER', 'phoneNumberCountryCode' => '46', 'removeLeadingZeroFromPhoneNumber' => 'true', ] ],
您可能最终需要完全重写文件_protected/vendor/thomasdilts/sms_worshiphhn_ip1/SmsForIp1.php,使其与您的短信供应商兼容。通过“重写”我的意思是从另一个文件和类中复制,然后进行重写。您的类必须是thomasdilts\sms_worshiphhn\Sms的子类,以便WorshipHHN可以使用。