[ABD] phpBB Social Network 0.7.2

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
User avatar
djchrisnet
Registered User
Posts: 95
Joined: Thu Sep 20, 2007 3:39 pm
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by djchrisnet » Fri Mar 19, 2010 3:57 pm

/**
*
* @package phpBB3
* @version $Id: chat.php 0.1.0
* @copyright (c) 20010 Kamahl http://www.phpbb3hacks.com
*
*/
funny year :)

I hope you are alive when the copyright begins xD

issjut
Registered User
Posts: 113
Joined: Tue Oct 09, 2007 5:02 am
Location: Berlin, Germany

Re: [BETA] Facebook chat with fixed bottom bar

Post by issjut » Fri Mar 19, 2010 4:09 pm

djchrisnet wrote:I hope you are alive when the copyright begins xD
And I hope I can send a message to other users with this mod before the copyright date is reached^^ :D :D
sorry for my bad English ;-)

User avatar
Kamahl19
Registered User
Posts: 1598
Joined: Tue Nov 06, 2007 3:33 pm
Location: Slovakia
Name: Martin
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by Kamahl19 » Sun Mar 21, 2010 6:34 pm

issjut wrote:
djchrisnet wrote:I hope you are alive when the copyright begins xD
And I hope I can send a message to other users with this mod before the copyright date is reached^^ :D :D
it runs with prosilver even now. there is just a small problem with other styles. i hope i will fix it until 20010 too


gennyna
Registered User
Posts: 72
Joined: Mon Apr 06, 2009 7:29 pm

Re: [BETA] Facebook chat with fixed bottom bar

Post by gennyna » Tue Mar 30, 2010 1:31 pm

can i used this mod with Subsilver? :roll:

superj707
Registered User
Posts: 1136
Joined: Thu Feb 26, 2009 12:20 am

Re: [BETA] Facebook chat with fixed bottom bar

Post by superj707 » Tue Mar 30, 2010 7:51 pm

I wish this mod had an ACP option that allows the site owner to set the mod such that only friends are shown in the online list for all users.

simvader
Registered User
Posts: 144
Joined: Thu Sep 06, 2007 5:54 pm
Location: Netherlands
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by simvader » Tue Mar 30, 2010 8:07 pm

looks like this is not worked on anymore.. :(

User avatar
Kamahl19
Registered User
Posts: 1598
Joined: Tue Nov 06, 2007 3:33 pm
Location: Slovakia
Name: Martin
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by Kamahl19 » Tue Mar 30, 2010 10:45 pm

I definitely continue in developing this MOD, I myself consider it as the best chat solution for phpbb, but you all have to wait a little, i dont have time for MODs now :) Appreciate that you like my MOD :)

gennyna
Registered User
Posts: 72
Joined: Mon Apr 06, 2009 7:29 pm

Re: [BETA] Facebook chat with fixed bottom bar

Post by gennyna » Wed Mar 31, 2010 8:24 am

then again you can adapt it to subsilver?

User avatar
Kamahl19
Registered User
Posts: 1598
Joined: Tue Nov 06, 2007 3:33 pm
Location: Slovakia
Name: Martin
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by Kamahl19 » Wed Mar 31, 2010 12:34 pm

yes, but later. priorite no.1 is solve the IDs problem and compatibility with all prosilver styles

sitwi
Registered User
Posts: 83
Joined: Fri Jul 21, 2006 10:53 am
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by sitwi » Wed Mar 31, 2010 4:45 pm

simvader wrote:looks like this is not worked on anymore.. :(
Geez, give the guy a chance, he only put it up this month?

nagwani
Registered User
Posts: 5
Joined: Wed Mar 31, 2010 10:09 pm

Re: [BETA] Facebook chat with fixed bottom bar

Post by nagwani » Wed Mar 31, 2010 11:02 pm

Alright, been up almost 6 hours straight since I've seen this amazing mod and it is almost 4:30 AM now!!!. Loved the mod and have integrated with IcyPhoenix's Black Pearl theme on my forums.

The user ids showing up instead of the username was nagging me no end, so I decided to give it a shot and here is what I have been able to come up with. Please bear with me if you find any issues with mod mod :D as I've tackled coding after almost 4 years and been using phpBB only for about 15 days.

One of the issues I know still remains is that of the document.title. The blinking title still reads the user_id instead of the username and am too exhausted to tackle that at this moment.

To get the username showing up, you need to edit 3 files:

overall_header.html
Find:

Code: Select all

<a href="javascript:void(0)" onclick="javascript:chatWith('{online_row.USER_ID}')">{online_row.AVATAR} <span>{online_row.USERNAME}</span>{online_row.STATUS}</a>
Replace with:

Code: Select all

<a href="javascript:void(0)" onclick="javascript:chatWith('{online_row.USER_ID}', '{online_row.USERNAME}')">{online_row.AVATAR} <span class="chatlist">{online_row.USERNAME}</span>{online_row.STATUS}</a>
chat.php
Find:

Code: Select all

  $sql = 'SELECT * FROM ' . CHAT_TABLE . '
            WHERE (' . CHAT_TABLE . '.to = "'.$db->sql_escape($_SESSION['user_id']).'" AND recd = 0)
            ORDER BY id ASC';
Replace with:

Code: Select all

  $sql = 'SELECT ' . CHAT_TABLE . '.*, ' . USERS_TABLE . '.username FROM ' . CHAT_TABLE . ', ' . USERS_TABLE . '
            WHERE (' . CHAT_TABLE . '.to = "'.$db->sql_escape($_SESSION['user_id']).'" AND recd = 0 AND ' . USERS_TABLE . '.user_id=' . CHAT_TABLE . '.from)
            ORDER BY id ASC';
Find:

Code: Select all

		$items .= <<<EOD
					   {
			"s": "0",
			"f": "{$chat['from']}",
Add After:

Code: Select all

			"fu": "{$chat['username']}",
Find:

Code: Select all

	$_SESSION['chatHistory'][$chat['from']] .= <<<EOD
		 {
			"s": "0",
			"f": "{$chat['from']}",
Add After:

Code: Select all

			"fu": "{$chat['username']}",
chat.js
Find:

Code: Select all

var user_id;
Add After:

Code: Select all

var username;
Find:

Code: Select all

function chatWith(chatuser) {
	createChatBox(chatuser);
Replace with:

Code: Select all

function chatWith(chatuser, chatboxUsernameAsTitle) {
	createChatBox(chatuser, chatboxUsernameAsTitle);
Find:

Code: Select all

function createChatBox(chatboxtitle,minimizeChatBox) {
Replace with:

Code: Select all

function createChatBox(chatboxtitle,chatboxUsernameAsTitle,minimizeChatBox) {
Find:

Code: Select all

	.html('<div class="chatboxhead"><div class="chatboxtitle">'+chatboxtitle+'</div><div class="chatboxoptions"><a href="javascript:void(0)" onclick="javascript:toggleChatBoxGrowth(\''+chatboxtitle+'\')">-</a> <a href="javascript:void(0)" onclick="javascript:closeChatBox(\''+chatboxtitle+'\')">X</a></div><br clear="all"/></div><div class="chatboxcontent"></div><div class="chatboxinput"><textarea class="chatboxtextarea" onkeydown="javascript:return checkChatBoxInputKey(event,this,\''+chatboxtitle+'\');"></textarea></div>')
Replace with:

Code: Select all

	.html('<div class="chatboxhead"><div class="chatboxtitle">'+chatboxUsernameAsTitle+'</div><div class="chatboxoptions"><a href="javascript:void(0)" onclick="javascript:toggleChatBoxGrowth(\''+chatboxtitle+'\')">-</a> <a href="javascript:void(0)" onclick="javascript:closeChatBox(\''+chatboxtitle+'\')">X</a></div><br clear="all"/></div><div class="chatboxcontent"></div><div class="chatboxinput"><textarea class="chatboxtextarea" onkeydown="javascript:return checkChatBoxInputKey(event,this,\''+chatboxtitle+'\');"></textarea></div>')
Find:

Code: Select all

					createChatBox(chatboxtitle);
Replace with:

Code: Select all

					createChatBox(chatboxtitle, item.fu);
Find:

Code: Select all

					newMessagesWin[chatboxtitle] = true;
					$("#chatbox_"+chatboxtitle+" .chatboxcontent").append('<div class="chatboxmessage"><span class="chatboxmessagefrom">'+item.f+':&nbsp;&nbsp;</span><span class="chatboxmessagecontent">'+item.m+'</span></div>');
Replace with:

Code: Select all

					newMessagesWin[chatboxtitle] = true;
					$("#chatbox_"+chatboxtitle+" .chatboxcontent").append('<div class="chatboxmessage"><span class="chatboxmessagefrom">'+item.fu+':&nbsp;&nbsp;</span><span class="chatboxmessagecontent">'+item.m+'</span></div>');
Find:

Code: Select all

				$("#chatbox_"+chatboxtitle+" .chatboxcontent").append('<div class="chatboxmessage"><span class="chatboxmessagefrom">'+user_id+':&nbsp;&nbsp;</span><span class="chatboxmessagecontent">'+message+'</span></div>');
Replace with:

Code: Select all

				$("#chatbox_"+chatboxtitle+" .chatboxcontent").append('<div class="chatboxmessage"><span class="chatboxmessagefrom">'+username+':&nbsp;&nbsp;</span><span class="chatboxmessagecontent">'+message+'</span></div>');
Find:

Code: Select all

		user_id = data.user_id;
Add After:

Code: Select all

		username = data.username;
Find:

Code: Select all

					createChatBox(chatboxtitle,1);
Replace with:

Code: Select all

					createChatBox(chatboxtitle,item.fu,1);
Find:

Code: Select all

				} else {
					$("#chatbox_"+chatboxtitle+" .chatboxcontent").append('<div class="chatboxmessage"><span class="chatboxmessagefrom">'+item.f+':&nbsp;&nbsp;</span><span class="chatboxmessagecontent">'+item.m+'</span></div>');
				}
Replace with:

Code: Select all

				} else {
					$("#chatbox_"+chatboxtitle+" .chatboxcontent").append('<div class="chatboxmessage"><span class="chatboxmessagefrom">'+item.fu+':&nbsp;&nbsp;</span><span class="chatboxmessagecontent">'+item.m+'</span></div>');
				}
This may be a crude hack and Kamahl may be able to integrate it better.

Cheers,
DeeJay

nagwani
Registered User
Posts: 5
Joined: Wed Mar 31, 2010 10:09 pm

Re: [BETA] Facebook chat with fixed bottom bar

Post by nagwani » Thu Apr 01, 2010 12:08 am

There is one step I forgot in the post above.

In chat.php

Find:

Code: Select all

"user_id": "<?php echo $_SESSION['user_id'];?>",
Add After:

Code: Select all

"username": "<?php echo $_SESSION['username'];?>",
Without this, the sender will see "undefined" in the chatbox of his/her session against the messages sent by him/her.

Cheers,
DeeJay

User avatar
Ahri89
Registered User
Posts: 516
Joined: Sat Apr 07, 2007 2:53 pm
Location: Spain
Contact:

Re: [BETA] Facebook chat with fixed bottom bar

Post by Ahri89 » Thu Apr 01, 2010 2:14 am

Subscribed, thanks!
MODs translated to Spanish: ACP Add User MOD, ACP Announcement Centre, Advertisement Management, Custom Profile Fields, Update Reminder, Flood time setting per forum, MOD Version Check, Posting template, Prune Log, Simple Trash Bin, TinyPic Plugin, User Reminder, View Profile, View your topics, and more...

Sorry for my bad english xD

pegasus81
Registered User
Posts: 97
Joined: Thu Apr 01, 2010 7:27 am

Re: [BETA] Facebook chat with fixed bottom bar

Post by pegasus81 » Thu Apr 01, 2010 7:35 am

Hi nagwani. I tried the changes you have proposed, but chat doesn't work. I've noticed that your style is based on subsilver as mine. May you help me? This is my forum: http://ingegneriapisa.altervista.org/index.php. Thanks. :)

Locked

Return to “[3.0.x] Abandoned MODs”