Introduction To send SMS from website for any application, you have to purchase sms credits from any sms provider and It is very simple to do this through your application . Now a days TRAI has been made some restrictions for sending SMS in india . Description To send sms we have to use api http request .before doing that we should have enough sms credit in your account with a registered account with any sms service provider . C# Sample Codepublic string apicall(string url) // API Push { HttpWebRequest httpreq = (HttpWebRequest)WebRequest.Create(url); try { HttpWebResponse httpres = (HttpWebResponse)httpreq.GetResponse(); StreamReader sr = new StreamReader(httpres.GetResponseStream()); string results = sr.ReadToEnd(); sr.Close(); return results; } catch { return "0"; } }public void SendSMS() { try { mobile = "to number"; message2 = "Your sms here '"; username = "your user name"; password = "your pwd"; domian = "sms.scibero.com"; senderid = "sender"; string result = apicall("http://" + domian + "/pushsms.php?username=" + username + "&password=" + password + "&sender=" + senderid + "&to=" + mobile + "&message=" + message2); if (!result.StartsWith("Wrong Username or Password")) { //ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "success", "alert('Message Sent')", true); } else { // ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "success", "alert('Message Sending Failed')", true); } } catch { } }
|
I am Johnson Augustine [My friends calls me - J.A), Completed my Master of Computer Applications degree, and Currently working as a Software Engineer at KTS Infotech PVT LTD and Server Admin and security Engineer at Scibero Hosting and Cyber Solutions. I have expertise in C/C++/Visual C++/G++/QT++,Com,Device Driver and embedded System Development. I have 4 Year Experience in ASP.net and Visual studio 2005,2008,2010 and MSSQL Server 2000,2005,2008 ,I have also deep knowledge in Oracle database,MySQL Database,C++ with SQLite, Android mobile development , PHP , Joomla,Word Press ,html,Javascript,Jquery,Ajax.CSS , Networking ,Cyber security, Ethical Hacking and familiar with most of the web hosting control panels like Plesk 9.5,Plesk 10.4.4,Plesk 11.0.9 . Cpanel/WHM,Hsphere,Dotnet panel , and have experience in Windows server 2003,2008,Cent Os , RHEL,Fedora etc .and also have some work experience in cloud environment.
|