I followed the wonderful tutorial by Will at developmentseed.org, and my phone received a confirmation code, but when I'm supposed to receive a text on an updated page the text is sent as a phone number with no domain. This is the email that I get as a result:

<55555555@>:
216.120.227.142 does not like recipient.
Remote host said: 501 <5555555@>: domain missing or malformed
Giving up on 216.120.227.142.

I changed the number from my actual telephone number. Am I missing something here? Is there some code I need to edit? I'm a high school teacher using Drupal 6.6 trying to deliver content updates to students via sms (email gateway) and I appreciate any help.

If this is not the correct forum to ask for help, then I apologize.

Comments

Will White’s picture

Hey there,
Glad you liked the tutorial. What are you specifying for the "Carrier" field?

grainybazzles’s picture

T-Mobile. But I tried a different number for Verizon and got the same result.

grainybazzles’s picture

In a further development, SMS Blast does work. So I guess I can get by with that for now.

rick hood’s picture

I am having a similar problem. Email notifications of content changes work fine, the 'Send to phone' link on posts works fine for sending SMS, but SMS notifications of content changes do not work and I get this error in the logs:

"Error sending e-mail (from me@mydomain.com to 5555555555@)."

In the error above, it is as if the domain is not getting appended. It should be 5555555555@vtext.com (verizon).

I figure SMS must be set up OK though because 'Send to phone' works fine.

In the sms_user table, for me the entry seems OK: a:1:{s:7:"carrier";s:9:"vtext.com";}

Drupal 6.6, Messaging 6.x-1.0, Notifications 6.x-1.0, SMS Framework 6.x-1.0-beta1

For sending SMS just using E-mail Gateway via Drupal mail.

rick hood’s picture

I found that if I hard code in my carrier on line 40 of sms_email_gateway.module it works (content notification via SMS works).

function sms_email_gateway_send($number, $message, $options) {
  $from = !empty($options['from']) ? $options['from'] : NULL;
  $to = $number .'@'. $options['carrier'];  /* if I replace '@'. $options['carrier'] with '@vtext.com' it works */
  $params['message'] = $message;
  $message = drupal_mail('sms_email_gateway', 'sms', $to, language_default(), $params, $from);
  if ($message['result']) {
    return array('status' => TRUE);
  }
}

Somehow this is not getting back the right carrier value:

$options['carrier']

The values in the sms_user table are:
uid: 1
delta: 0
number: 5555555555
code: blank
gateway: a:1:{s:7:"carrier";s:9:"vtext.com";}

rick hood’s picture

Found the problem. Needed this patch to Messaging (messaging_sms.module): http://drupal.org/node/337518

grainybazzles’s picture

That did the trick, Rick. Thanks for the link.

Will White’s picture

Component: E-mail Gateway » Core Framework
Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

rothatboat’s picture

I continue to get the error with the 'carrier' not being added on for the email to send:

'Unable to send e-mail. Please contact the site administrator if the problem persists.'

The patch has not solved it, and I'm using the latest release of the sms framework. I have tried inputting the 'carrier' manually into the sms email gateway and that worked. But my users have various providers. Is there any solution to this problem on Drupal 6.13?

Thanks in advance.