Hi.

I am working on a HRMS system in J2EE. Here i need to verify mobile number through sms.

I am reading about it from 2 days but didn't get anything except SMPP. It will take a long time for me to learn this and implement whole.

I need suggestion for this. And if SMPP is the only solution then good resource link for that.

Thanks

You can send SMS messages anywhere you can send email. You need to know the user's carrier (e.g. Verizon, Alltell, Sprint, AT&T, etc) and then you can lookup the carrier-specific email suffix to use. For example (PHP, but can be adapted to JSP quickly):

switch ($cair) {
	  case "1":
		  // Alltel: phonenumber@message.alltel.com
		  $email = $number . '@message.alltel.com';
		  break;
	  case "2":
		  // AT&T: phonenumber@txt.att.net
		  $email = $number . '@txt.att.net';
		  break;
	  case "3":
		  // Boost Mobile: number@myboostmobile.com
		  $email = $number . '@myboostmobile.com';
		  break;
	  case "4":
		  // Cingular: phonenumber@cingularme.com
		  $email = $number . '@cingularme.com';
		  break;
	  case "5":
		  // Nextel: phonenumber@messaging.nextel.com 
		  $email = $number . '@messaging.nextel.com ';
		  break;
	  case "6":
		  // Powertel: phonenumber@ptel.net
		  $email = $number . '@ptel.net';
		  break;
	  case "7":
		  // Sprint: phonenumber@messaging.sprintpcs.com
		  $email = $number . '@messaging.sprintpcs.com';
		  break;
	  case "8":
		  // SunCom: phonenumber@tms.suncom.com
		  $email = $number . '@tms.suncom.com';
		  break;
	  case "9":
		  // T-Mobile: phonenumber@tmomail.net
		  $email = $number . '@tmomail.net';
		  break;
	  case "10":
		  // Verizon: phonenumber@vtext.com
		  $email = $number . '@vtext.com';
		  break;
	  case "11":
		  // Virgin Mobile: phonenumber@vmobl.com
		  $email = $number . '@vmobl.com';
		  break;
	  case "12":
		  // US Cellular: phonenumber@email.uscc.net
		  $email = $number . '@email.uscc.net';
		  break;
  }

Given the user's number, and these suffixes, you can use JavaMail to send the SMS via your local mail server.

Thanks for replying man. But i am in gujarat and i m not getting carrier specific email addresses for service providers in gujarat. I tried some from my hotmail account but it is not delivering sms.

I think this is a temporary or improper way to use implement this service.

Hi Hardik,

I have written a code that will send sms from the app. But you can only achieve this if you have a SMTP server configured. Your java code will establish a connection with the SMTP server and then send the packets to a particular mobile no.

Regards,
Suvojit

Hi Rajini,
I found solution for this problem.. highlevel the solution is there are sites who will provide you any URL with member registration...
all you have to build a query string with the given parameters like phonenumber and message... you can find lot many such providers just search "bluk sms" providers..
Hope this will helps u
if u need any more info/help email me : <EMAIL SNIPPED>

suvojit.dhole - I think i got your point but i am not getting that SMTP and SMPP are both different protocols then how can i send message to mobile through SMTP server. Would you please clarify more about this.

buzzi - Yeah you are right i got some provider. But by luck my company won't allow me to pay for that. :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.