7 Replies Latest reply on Nov 14, 2016 12:53 AM by Hiren

    Openfire - interface - to MySQL Tables (SMS)

    Steve

      I am new to OPENFIRE and messging software in general.

       

      I have two tables in a MYSQL database that is setup to send/receive text messages (SMS) to the world.

       

      I am wondering if anyone has done anything like this before and if this is even possible.

       

      I looked to see if SPARK was available in the Android Play Store, I didn't see it in there.  What client for Android and iPhone is used with OpenFire?

       

      incoming table

      +---------+--------------+------+-----+---------+-------+

      | Field   | Type         | Null | Key | Default | Extra |

      +---------+--------------+------+-----+---------+-------+

      | date    | varchar(50)  | YES  |     | NULL    |       |

      | from    | varchar(50)  | YES  |     | NULL    |       |

      | to      | varchar(50)  | YES  |     | NULL    |       |

      | message | varchar(200) | YES  |     | NULL    |       |

      | ip      | varchar(200) | YES  |     | NULL    |       |

      | result  | varchar(200) | YES  |     | NULL    |       |

      +---------+--------------+------+-----+---------+-------+

      outgoing table

      +---------+--------------+------+-----+---------+-------+

      | Field   | Type         | Null | Key | Default | Extra |

      +---------+--------------+------+-----+---------+-------+

      | date    | varchar(50)  | YES  |     | NULL    |       |

      | from    | varchar(50)  | YES  |     | NULL    |       |

      | to      | varchar(50)  | YES  |     | NULL    |       |

      | message | varchar(200) | YES  |     | NULL    |       |

      | ip      | varchar(200) | YES  |     | NULL    |       |

      | result  | varchar(200) | YES  |     | NULL    |       |

      +---------+--------------+------+-----+---------+-------+

       

      Would it be possbile to use these two MYSQL tables to interface to Openfire and use a client to do texting using OpenFire and an OpenFire compatible client?

       

      TIA

        • Re: Openfire - interface - to MySQL Tables (SMS)
          Hiren

          Hi,

           

          Why are you have used two different table for incoming and outgoing message insted of you can handle all message in one table?

           

          There are lot's of application which is using openfire server for delivering sms to client. you can download spark application from

           

          Ignite Realtime: Downloads

          • Re: Openfire - interface - to MySQL Tables (SMS)
            wroot

            What client for Android and iPhone is used with OpenFire?

             

            XMPP | XMPP Clients

            • Re: Openfire - interface - to MySQL Tables (SMS)
              Steve

              I receive sms from whoever to  a few VOIP numbers that come into MySQL.  As I stated about there is an incoming/outgoing table.  I would like to interface either the tables to OPENFIRE.  I receive the sms via PHP and it puts the sms into MySQL.

               

              Or.....

              Interface OPENFIRE with the php code to receive/send sms so that I can use clients on Android, IOS or a phone, desktop or tablet to send/receive SMS from my DID's from any of my devices.

               

              I hope that is more clear as to what I would like to accomplish.

              • Re: Openfire - interface - to MySQL Tables (SMS)
                Steve

                I would like to use OpenFire to communicate to a SMS Provider using .php.  They set up a couple of .php files called receivesms.php and sendsms.php.  They way they set it up doesn't do me a lot of good.  receivesms.php puts the sms txt into a mysql table called incoming.  When you run the sendsms.php I have to put my api key in, the to, from and the message and then hit send from the server housing the mysql database and php scripts.

                 

                I would like to have help in re-writing the php scripts so that I can use OpenFire to communicate using php to my provider to send/receive sms using Openfire.

                 

                I have found the Bria for iPhone and Bria for Android has an XMPP clients that work with Openfire. 

                 

                I have a couple DID's set up that will receive or and I can SMS from using the above program that they wrote for me.

                 

                I would like to be able to send/receive sms using BRIA/Openfire real time.  Storing all SMS messages on the Openfire Server would be a plus.

                 

                Any help from anyone would be greatly appreciated.  I am not a programmer but I really like to learn this stuff.

                 

                Anyone that can help me and is willing please let me know.

                 

                Thanks very much.

                  • Re: Openfire - interface - to MySQL Tables (SMS)
                    Hiren

                    hi steve,

                     

                    if you want to store incoming and outgoing message in openfire server in any of your database you can use monitoring plugin in openfire it will create nee table called ofmessagearchive and store all message which is passed through openfire and i still can not figure out why you have used two table instead you can manage it using one table.

                     

                    you can create one table and create two column "to" and "from" and store this value respectivly from  message and you can detect message is either incoming or outgoing.