{"id":105,"date":"2010-05-21T12:38:19","date_gmt":"2010-05-21T11:38:19","guid":{"rendered":"https:\/\/www.onverify.com\/blog\/?p=105"},"modified":"2024-11-15T07:35:30","modified_gmt":"2024-11-15T07:35:30","slug":"how-to-send-sms-from-your-website-using-onverify-com","status":"publish","type":"post","link":"https:\/\/www.onverify.com\/blog\/2010\/05\/21\/how-to-send-sms-from-your-website-using-onverify-com\/","title":{"rendered":"How to Send SMS from your website using OnVerify.com"},"content":{"rendered":"<p>SMS, which is abbreviation of Short Message service, is the most commonly used feature of a mobile phone after the phone call. Although it&#8217;s limited to 160 characters, sending an sms text is very popular in several cases like;<\/p>\n<ul>\n<li>A phone call is not possible<\/li>\n<li>A phone call will cost more than sending an sms message<\/li>\n<li>It&#8217;s more fun to send sms text rather than talking at that time.<\/li>\n<\/ul>\n<p>There are just a few samples for individuals use sms text to communicate.<\/p>\n<p>But if you own a web site, adding an sms service to your site, can be cool, and cutting edge. Also adds another form of communication with your customers, and your web site.<\/p>\n<p>Some of the examples of sms service at your web site can be listed, but not limited to:<\/p>\n<ul>\n<li>Customer Verification with SMS message<\/li>\n<li>Notification of special events\/products\/discounts via SMS text<\/li>\n<li>Notification to your self about some cases at your web site<\/li>\n<li>SMS Text Marketing of your opt-in lists (You cannot just send sms to any number without a prior approval)<\/li>\n<\/ul>\n<p>Samples continue.<\/p>\n<p>There are several sms service providers in Internet world. But at OnVerify.com, we provide the easiest solution with standard features, at a competitive price. You don&#8217;t need to write long sms software to send sms text from your web site.<\/p>\n<p>Firstly you need to open a free account at OnVerify.com. It&#8217;s free, gives you $0.25 credit when you complete Phone Verification process automatically. Then get your userid and apipass from documentation or profile page, and paste the code below in your favorite php editor:<\/p>\n<blockquote><p>$f = file(&#8220;http:\/\/www.onverify.com\/sms.php?userid=youruserid&amp;apipass=apipass&amp;msg=test&amp;number=number&#8221;);<\/p><\/blockquote>\n<p>That single line of code will initiate a sms text sending from your web site easily. Let me explain the parameters:<\/p>\n<blockquote><p>userid=youruserid, this is the userid you get from onverify.com, \u00a0we need to recognize you<\/p>\n<p>apipass=yourapipass, this is the api password you get from onverify.com to authenticate you<\/p>\n<p>msg=test, this is the text message we will send to the mobile number. remember to urlencode your message before feeding it to here.<\/p>\n<p>number=number, this is the number we will send sms text message to. It must be in international numbering format; country code + area code + number (like 18581234567)<\/p><\/blockquote>\n<p>On return, you&#8217;ll have a single line. Which is a numeric code, that you may want to check.<\/p>\n<blockquote><p>switch($f[0]) {<br \/>\ncase &#8220;2&#8221;:<br \/>\necho &#8220;username or password is wrong&#8221;;<br \/>\nbreak;<br \/>\ncase &#8220;3&#8221;:<br \/>\necho &#8220;balance is not enough&#8221;;<br \/>\nbreak;<br \/>\ncase &#8220;4&#8221;:<br \/>\necho &#8220;number wrong&#8221;;<br \/>\nbreak;<br \/>\ncase &#8220;6&#8221;:<br \/>\necho &#8220;ip restriction&#8221;;<br \/>\nbreak;<br \/>\ncase &#8220;7&#8221;:<br \/>\necho &#8220;dublicate vid&#8221;;<br \/>\nbreak;<br \/>\ndefault:<br \/>\nif ($f[0]&gt;100) echo &#8220;sms is queued&#8221;;<br \/>\n}<\/p><\/blockquote>\n<p>Let me explain. At first step we send to request to OnVerify.com&#8217;s sms service. We get a numeric code from that page, which can be 2,3,4,6,7 or &gt;100. \u00a0each meaning something.<\/p>\n<blockquote><p>2: username or apipass is wrong. please re check and compare them with OnVerify.com<\/p>\n<p>3: balance is not enough. OnVerify.com works from positive balance. But don&#8217;t worry during the tests and integrations. Just drop us an e-mail to support@onverify.com. Ask for more credits, and explain your project. We are more than happy to help<\/p>\n<p>4. number wrong. Yes it must be in international format. Which is country code + area code + number<\/p>\n<p>6. restricted ip. You can limit the server&#8217;s ip that the calls with be initiated from<\/p>\n<p>7. dublicate vid. This is used for callback firing. At the end of sms sending we fire a callback to your system explaning the status of the sms. (sent, unsent, cost, etc)<\/p><\/blockquote>\n<p>Sending a SMS text is asynchronous at onverify.com. Which means, when you initiate a sms sending, OnVerify.com will return you immediately if this call is accepted or not. Later, it will notify you with sending a request to the callback url that you set at sms text message initiation step.<\/p>\n<p>In this article, I tried to show how easy it&#8217;s to send sms text message to any phone using OnVerify.com&#8217;s services. \u00a0In order to send sms text, you dont need to setup\/develop big sms software, just use the sms service feature of OnVerify.com<\/p>\n","protected":false},"excerpt":{"rendered":"<p>SMS, which is abbreviation of Short Message service, is the most commonly used feature of a mobile phone after the phone call. Although it&#8217;s limited to 160 characters, sending an sms text is very popular in several cases like; A<span class=\"ellipsis\">&hellip;<\/span><\/p>\n<div class=\"read-more\"><a href=\"https:\/\/www.onverify.com\/blog\/2010\/05\/21\/how-to-send-sms-from-your-website-using-onverify-com\/\">Read more <span class=\"screen-reader-text\">How to Send SMS from your website using OnVerify.com<\/span><span class=\"meta-nav\"> &#8250;<\/span><\/a><\/div>\n<p><!-- end of .read-more --><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_seopress_robots_primary_cat":"","footnotes":""},"categories":[5],"tags":[58,52,53,54,57,50,56,55,49,51,8],"class_list":["post-105","post","type-post","status-publish","format-standard","hentry","category-onverify-com","tag-customer-verification","tag-send-sms","tag-send-sms-message","tag-send-sms-message-from-web-site","tag-sms-marketing","tag-sms-message","tag-sms-service","tag-sms-software","tag-sms-text","tag-sms-text-message","tag-sms-verification"],"_links":{"self":[{"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/posts\/105","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/comments?post=105"}],"version-history":[{"count":4,"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/posts\/105\/revisions"}],"predecessor-version":[{"id":474,"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/posts\/105\/revisions\/474"}],"wp:attachment":[{"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/media?parent=105"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/categories?post=105"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.onverify.com\/blog\/wp-json\/wp\/v2\/tags?post=105"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}