SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Xubuntu, Mythbuntu, Lubuntu, Picuntu, Mint 18.1, Debian Jessie
Posts: 1,207
Rep:
Slack server IM to cell phone?
My Slackware 11 server is always connected to the internet with a DSL router. I have an old Nokia 1100 Tracfone that is able to get text messages. I found a site that can IM my cell phone over the net. What I want to do is have my Slacware box grab weather info each day and then IM that info to my cell. Is this possible?
I don't know if your service is similar, but with my cellphone provider, text messages are handled just like email.
There is a domain (vtext.com, I think). And you just send an email to the number with the domain tacked on, like 12345678@vtext.com.
If that is the case for you as well, then you can sent email out to the phone with a simple script. For example, I have used this script to send HDD usage text messages to my phone by just plugging in the appropriate email address.
Code:
#!/usr/bin/perl
#
# Script to check HDD use and mail to to an address.
$HOST=`cat /etc/HOSTNAME`;
chomp($HOST);
@retval=`df -h`;
$dt=`date`;
chomp($dt);
open(MAIL,"|/usr/lib/sendmail -t");
print MAIL "From: diskusage\@mydomain.com\n";
print MAIL "To: me\@mydomain.com\n";
print MAIL "Subject: Disk Space ($HOST)\n";
print MAIL "\n";
print MAIL "@retval\n\n";
print MAIL "$HOST\n";
close (MAIL);
Distribution: Xubuntu, Mythbuntu, Lubuntu, Picuntu, Mint 18.1, Debian Jessie
Posts: 1,207
Original Poster
Rep:
Here's a nice 3 day forecast in text...the banners and html need to be stripped. How could I do this and then put the resulting text file in the message field and then use the above limit of 160?
For the text forecast that wget won't get, I don't know it said :
'You have entered an invalid station id. An error has occurred. Exiting the script!'
I don't know, maybe it wants hidden field value or cookies, or something wrong
in the url variables...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.