Nik has asked for the wisdom of the Perl Monks concerning the following question:

#/usr/bin/perl -w use WWW::SMS; my $sms = WWW::SMS->new("36973814824", "This is a test!"); for ( $sms->gateways(sorted => 'reliability') ) #for every compati +ble gateway { if ( $sms->send( $_ ) ) { #try to send sms last; #until it succeds } else { print $WWW::SMS::Error; #here is the erro +r } }

when i try to run it i get No matching international prefix found at C:/Perl/site/lib/WWW/SMS.pm line 36
Failed at step 1 of module GoldenTelecom.pm

does anyona have a workign module to help me sent sms??

20030804 Edit by Corion: Added formatting

Replies are listed 'Best First'.
Re: notify by sms!
by antirice (Priest) on Aug 04, 2003 at 09:53 UTC

    Golden Telecom no longer allows international SMS messages as is explained here. As such, the number of countries that WWW-SMS will work with has been reduced.

    Unfortunately the module does not support Hungary at this time. Right now it supports the following countries: Bulgaria, Finland, Germany, Italy, Russia, Spain and the UK.

    If you could find a SMS internet gateway for Hungary, you could submit it to the development team and hope they add support.

    Hope this helps.

    antirice    
    The first rule of Perl club is - use Perl
    The
    ith rule of Perl club is - follow rule i - 1 for i > 1

      what about if i want to sent sms in a greek mobile phone? there is no support for greece anywhere? must i find a module or something??

        Same for Greece, unfortunately. Again, if you can find someplace on the net that allows for you to send SMS messages to Greek phones, submit it to the development team and they may be able to help you out. Of course, you could roll your own as the module itself just uses a bunch of other modules to actually get the information. The module is just a method of abstracting out the multiple implementations to provide a single interface.

        antirice    
        The first rule of Perl club is - use Perl
        The
        ith rule of Perl club is - follow rule i - 1 for i > 1

Re: notify by sms!
by bm (Hermit) on Aug 04, 2003 at 09:44 UTC
    You need to add a country code, prefixed with a + sign.

    The Uk country code is 44, for example, so that would mkae your constructor:

    my $sms = WWW::SMS->new("+4436973814824", "This is a test!");