The integration of FLASH is really simple using the XML capabilities of SMS Fox Box. Print E-mail


A lot of website are using FLASH technology because it offers the opportunity to create really nice interfaces with animations and user interaction.
In this page we will create a simple FLASH interface that show you the last SMS received.




As all other processes also this one is controlled by the main event handler.
The code below is the call to the module from event handler and it is a portion of it

.....
#Save messages in XML format
#if [ "$1" = "RECEIVED" ]; then
#/etc/sms/scripts/sms2xml $1 $2 $3
#fi
#
....

To activate de-activate the module you have always to remember to remove/add the # sharp character as
described in the Event Handler how to.

After the activation of the sms2xml script, each time you receive an SMS it will be stored to http:///xml/sms.xml
The format of the file sms.xml is as follow:




393494703237
text of the message


To load the XML file inside flash we need to write a little procedure with actionscript (Courtesy of Roberto Corti):

// Author: Roberto Corti
// Create new XML Object and set ignoreWhite true to ignore white spaces
messaggio = new XML();
messaggio.ignoreWhite = true;

// Load the XML file where your informations are stored
messaggio.load('sms.xml');

messaggio.onLoad = function (success) {
if (success) {
// If your XML Document is loaded succesfully you can procede with the for function
for (var n = 0; n
trace(n + ' ' + messaggio.firstChild.childNodes[n].firstChild.nodeValue);
}
// You can display the nodeValue into the stage using variables
from = messaggio.firstChild.childNodes[0].firstChild.nodeValue;
msg = messaggio.firstChild.childNodes[1].firstChild.nodeValue;
}
};

Click here to download the full example.
 
< Prev   Next >

FoxBox dedicated website

A new website dedicated to
SMS /MMS foxbox is online!
foxbox website

SMPP server interface

You are searching SMS speed?
KDEV SMS
http://www.smskdev.it



SMS gateway FoxBOx
buy foxbox
buy on FoxBox eShop



For further info contact us by mail This e-mail address is being protected from spam bots, you need JavaScript enabled to view it providing us the FoxBox model you need and your company details.


2009 KDEV di Davide Cantaluppi, P.IVA 02984320131
KDEV SMS è un servizio di KDEV System Development    FoxBox SMS-MMS Hardware Gateway - FoxBox appliance
SMS KDEV sms inbound SMS KDEV ricevi ed elabora tuoi SMS e invia SMS con altissime prestazioni

spacer.png, 0 kB
spacer.png, 0 kB