<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
<META content="MSHTML 5.00.3315.2870" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hello all, long time listener, first time
caller.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>I'm using Jabber on a server and working on a
client in Flash, for the purpose of multi-player game and chat environments. So
far Jabber has everything we need, except a way to easily store data about
rooms and determine game states. Say three people are playing a game show, all
three players send their answers to the server, which then must decide who's the
winner and send the relevant data back. Easy.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>I was thinking the best and most unintrusive way to
do this would be to create a custom namespace for gaming and
metadata. This namespace would actually be used to pass
the information off to PHP or Perl, which would then execute and write to a
temp file or stdout, read back in to jabberd, then sent to the client. For
security purposes tags would correspond to specific php scripts explicitly
stated in a config file.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>The reason behind using PHP or Perl is for ease of
use for web developers. I would like to create a bridge from Jabber
to these scripting tools to allow fast scripting of simple server-side
decision making for multi-player flash games. This also will allow metadata
on conference rooms etc. to be stored and retrieved from a database of the
developer's choice.</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>I figured first I'd ask if something like this
already exists. I've looked all over, but maybe it's out there, lurking under an
acronym i don't know. I'm not looking for a big reply to my big jdev debut.
It would be nice to have either a nod that it's a good idea and a couple links
to point me in the right direction, or someone to say, 'duh, that's been done
before, here's a tarball."</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>To be specific on what I want to make:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Client sends a SCRIPT tag:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2><SCRIPT name="chess"></FONT></DIV>
<DIV><FONT face=Arial size=2> <PARAM
name="move">checkmate</PARAM></FONT></DIV>
<DIV><FONT face=Arial size=2></SCRIPT></FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>jabberd receives tag, looks at its config file for
a match which looks like:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2><SCRIPTDEF name="chess"></FONT></DIV>
<DIV><FONT face=Arial size=2>
<APPTYPE>php</APPTYPE></FONT></DIV>
<DIV><FONT face=Arial size=2>
<FILE>/home/user/chess.php</FILE></FONT></DIV>
<DIV><FONT face=Arial size=2></SCRIPTDEF></FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>So the script 'chess' is passed the parameter move
and executed something like:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>/usr/bin/php/php -q chess.php
move=checkmate</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>PHP works its magic and then the data from the
script is sent back to the client as:</FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2><SCRIPT reply="chess"></FONT></DIV>
<DIV><FONT face=Arial size=2> ...php output....</FONT></DIV>
<DIV><FONT face=Arial size=2></SCRIPT></FONT></DIV>
<DIV> </DIV>
<DIV> </DIV>
<DIV><FONT face=Arial size=2>Thanks for any help</FONT></DIV>
<DIV><FONT face=Arial size=2>Chris</FONT></DIV>
<DIV> </DIV>
<DIV> </DIV></BODY></HTML>