Version: 1.00, by version
Developer Last Online: Nov 2002
Version: 2.2.x
Rating:
Released: 04-08-2002
Last Update: Never
Installs: 15
No support by the author.
YAPIH (Yet Another PHPMyChat Integration Hack) 1.0 by Joshua McNeese <jmcneese@enterthemuse.com>
Now, first off, this is not an 'out-of-the-box' hack, that you can just uncompress and change a config file and expect to work right off the bat. This hack was the result of me spending a considerable amount of time hand-editing files and replacing variables to convice PHPMyChat to use the VBulletin user database table. You will have to modify this to work with your server/configuration, and if you are not familiar with the PHP internals of VBulletin or with MySQL, turn back now. You have been warned.
(1) Uncompress YAPIH-1.0.zip in the ServerRoot of your server, so that you will access the chat via http://yourhost.com/chat/
(2) Execute the SQL commands in the file 'chat.sql'. This will create the tables needed for PHPMyChat as well as modify your user table. Altering your user table is dangerous, so be sure to have backups handy.
(3) Modify your VB templates:
ADD these two variables to your 'phpinclude' template:
This will replace any space in a username with spaces, as PHPMyChat does not accept spaces in names, and assign it to the variable $chatname. The users hashed password is assigned to $chatpass, for convenience.
(4) Edit the /chat/config/config.lib.php3 to match your server/configuation/preference.
(5) Now, the last (and tricky) part. What you have now is a working PHPMyChat installation that will authenticate on the VBulletin user table, if you followed the instructions faithfully and received no errors. What must be done now is provide your users with a way to access the chatrooms that you have created. I do this via a DHTML/PHP4 menu panel that lists the available chatrooms, and opens the chatroom in a 600x400 java popup box. You can do this anyway you want, so long as the link is provided via a template in VBulletin, or if you know how to pass variables to custom PHP scripts from within the 'phpinclude' template (which is what I do). The URL you must use is in this format:
Where $chatname and $chatpass are provided by the 'phpinclude' template, and $chatroom is provided by however you choose to assign that variable. It's up to you to figure out how you wish to do so, because everyone structures their site navigation in a different way.
To see the end-user representation of this hack, go to http://www.enterthemuse.com/ and login as 'test', password 'test'. On the left side of the site is a panel-based menu that will include a section 'Chat'. Take a look around, pay attention to where the URLs point and try it out.
It might work for you, it might not, it's totally dependent on your understanding of how to pass variables from your VB templates (in particular 'phpinclude'). Try it, and if all else fails, post your experiences on vb.org.