Monday , 24 July 2017

Make Your Own Website to Send SMS for Pakistanis

Make SMS Website for Pakistanis

Today I am here to talk about API and SMS gateway, so API means Application Programming Interface which is a code provided by websites so that we can use the code to use their features on our websites we can call it SDK (Software Development Kit) many websites provides SDK for different programming languages to access few of their features so Today I am going to share that how you can make a website to send SMS online for Pakistanis actually for this we need a SMS gateway and I know a website which provides us API or SMS gateway to send SMS (Short Message Service) online from our custom websites just remember we are going to use PHP language to make SMS website.

Make SMS Website for Pakistan

Recently I found a website and I am enjoying it recently I found few great features like send and receive SMS for free and post on social networks for free like on Facebook and Twitter and I also found an amazing feature which I decided to share with you actually the website that I am talking about is sendsms.pk and they provide us SMS gateway so we can make SMS website for free but the problem is that it is only for Pakistanis :(

First Get Hosting and Domain

So now let’s do some programming to make SMS website first obviously we need a hosting and a domain so that we can upload our PHP files to hosting to make a working SMS website but don’t worry you can get free hosting and domain too from 000webhost.com, hourb.com, byethost.com etc just choose any website however I recommend you to use 000webhost it’s great and amazing. I hope you can get your hosting account with domain from any of the websites shared above now let’s talk about how to use sendsms.pk’s API to make SMS website.

Register and Get API Key on SendSMS.pk

Now after getting hosting and domain it’s time to register on sendsms.pk, verify your account with your phone then login and just go to API page there you will see your API key (save it somewhere in your computer we are going to use it later) and username right below it you will see a button to download sample PHP files to send SMS using their API simply just click on that button to download the PHP SDK then extract the compressed folder in that folder you will see 3 files sms.phpexample-sendsms.phpindex.php the first one is the file where they have coded the class so you don’t really need to edit or change that file simply just leave it alone and the second file is the main file and the third file index.php is nothing you can delete it if you want to. After deleting the index.php now rename the example-sendsms.php file to index.php and open it up and replace the API key with your key (I told you to save it somewhere I hope you did now use it here) you can find it somewhere on line no. 38 if you are using Notepad++ or any other code editor. After replacing the API key now all you have to do is to upload sms.php and index.php (remember you changed the example-sendsms.php file to index.php) files to your hosting account using any FTP client tool or simply from cPanel.

Access your website using your domain name provided by the website from which you got hosting and domain. There you will two boxes in the first simply just add the destination number make sure it’s a Pakistani phone number and in the second box type in the message and click on the button to send SMS online for free, you can share your website with your friends so that they can use your website to send free SMS online

Anything You Did Not Understand?

Seriously if there is anything that you didn’t understand about this tutorial then please comment below without any hesitation I will be happy to help you and don’t forget to share it if you thinks it’s useful, God bless you :)

Leave a Reply