send sms to a phone number

maria_zk - February 13, 2009 - 15:16
Project:SMS Framework
Version:5.x-1.1
Component:Clickatell
Category:support request
Priority:normal
Assigned:Unassigned
Status:active
Description

Hello! I successfully implemented sms framework with Clickatell gateway, and i am trying to customize the sms_blast module so that it will send sms to one given number by the user. (Note that It works perfectly well in normal cases).

I changed the form with an input area and changed the function as following:

In the form creation i add (sms_blast.module)

  $form['customphone'] = array(
    '#type' => 'textfield',
    '#title' => t('Fill in the Phone number'),
'#description' => t('send to a phone number'),
    '#cols' => 12,
    '#rows' => 1,
  );

Then in the send function i add:

if ($nummer != '') {
//just mobiles in greece
$gateway = 'a:1:{s:7:"country";s:2:"30";}';
sms_send($form_values['customphone'], $form_values['message'], $gateway);
  }

But in the log i see the following error:
Sending SMS to %number failed. The gateway said ERR: 105, Invalid Destination Address

Any ideas why? I confirmed that $form_values['customphone'] passes the correct number, so I think that this is a gateway issue. Only that I cannot understand why it fails...

 
 

Drupal is a registered trademark of Dries Buytaert.