• Forum
  • Doc
  • Screenshots
  • Download
  • Donate
  • Contributors
  • Contact
  • Follow @phpfreechat
  • DEMO
  • Board index ‹ Version 1.x branch ‹ phpBB, Simple Machines Forum (SMF), and Forum Software (v1.x)
  • Change font size
  • FAQ
  • Register
  • Login

phpbb3 Integration

Moderators: OldWolf, re*s.t.a.r.s.*2

Post a reply
28 posts • Page 2 of 2 • 1, 2

Postby Bieneke » Thu Jan 03, 2008 12:14 am

[edit]
I got it to work, no idea how. I just tried it over and over again. I am using Larry's file. Thanks![]
[/edit]

I cannot get the integration script to work either. I get:

Fatal error: Call to a member function on a non-object in /home/blabla/public_html/html/dutch/chat/index.php on line 8

I used the script in the FAQ, I took an integral copy of Larry's file (and adjusted only the website specific values) and I keep getting the same error. Does anyone know what I do wrong?
Last edited by Bieneke on Thu Jan 03, 2008 3:27 am, edited 1 time in total.
Bieneke
New member
 
Posts: 1
Joined: Thu Jan 03, 2008 12:01 am
Top

Postby remmy » Sat Jan 05, 2008 3:59 pm

Well finally, by mere luck, I got it to work also.
I used Larry's "finished" script.

For me, the path to the phpBB root had to be
"../forum/" (replace forum with your folder name)

I thought that since both chat and forum were at peer levels, the leading periods weren't necessary. And I tried so many variations of the path name, I'm pretty sure I tried this before, and it didn't work.

ANYWAY, it's working now.

Now I want to bring over the Admin status from phpBB. So I have some more experimenting to do.
remmy
New member
 
Posts: 3
Joined: Sat Dec 29, 2007 8:45 pm
Top

Postby sfjuocekr » Sun Feb 10, 2008 7:03 pm

How do I make the redirect work?

ucp.php?mode=login?redirect=../chat/index.php

That would be it right? My chat is at xxx.xxx.xxx/chat and forum at xxx.xxx.xxx/forum why is phpBB trowing in sid? Now apache tells me it just cant find the file :s


Code: Select all
define('IN_PHPBB', true);
$phpbb_root_path = '../forum/';
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.' . $phpEx);

$user->session_begin();
$auth->acl($user->data);
$user->setup('viewforum');

get_username_string ;
$oog = $user->data [username];

if ($oog == "Anonymous") header("Location: http://xxx.xxx.xxx/forum/ucp.php?mode=login?redirect=../chat/index.php");

Why is this NOT redirecting?

The requested URL /index.php&sid=10fb2d1dc22018ec98561584e8f59086 was not found on this server.

http://xxx.xxx.xxx/forum/ucp.php?mode=l ... 95faa2ed62



What am I overlooking?



/edit: Im such a retard!

Watch me use ? instead of & ... sorry :p
Last edited by sfjuocekr on Sun Feb 10, 2008 7:17 pm, edited 1 time in total.
sfjuocekr
New member
 
Posts: 2
Joined: Sun Feb 10, 2008 6:50 pm
Top

Postby DreadPirateVane » Mon Aug 09, 2010 1:46 pm

So i am not understanding the problem here,, when you set it to redirect if not logged in all goes just fine till the actual redirect back to the chat page,, it goes to the right place only the url string has this extra feild on it

Code: Select all
index.php&sid=9957437d2d0dc5536bc98bbcd5c334a0

because of this it fails to open the chat index, is this some sort of cookie session that is being used and not allowing it to connect? any advise would be great, here is my index page code

Code: Select all
<?php


define("IN_PHPBB", true);
$phpbb_root_path = "../"; //Root to phpBB

$phpEx = substr(strrchr(__FILE__, "."), 1);
include($phpbb_root_path . "common." . $phpEx);

// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup('viewforum');

get_username_string ;
$oog = $user->data ['username'];

if ($oog == "Anonymous")
    {
      header("Location: ../ucp.php?mode=login&redirect=/../chat/index.php");
    }


if ($user->data['is_registered'])
    {
    include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
    $sql = "SELECT u.user_id, u.group_id, u.user_avatar, u.user_avatar_type, u.user_avatar_width, u.user_avatar_height, u.username, u.user_rank, u.user_colour
    FROM " . USERS_TABLE . ' AS u
    WHERE u.user_id = ' . $user->data['user_id'];
               
    $result = $db->sql_query($sql,300);

    $row = $db->sql_fetchrow($result);

   
    $avatar_img = get_user_avatar($row['user_avatar'], $row['user_avatar_type'], $row['user_avatar_width'], $row['user_avatar_height'], '',true);   
    $username_trim = (strlen($row['username']) > 9) ? substr($row['username'],0,9) . ".." : $row['username'];
    $u_profile    = get_username_string('full', $row['user_id'], $username_trim, $row['user_colour']);
                           
    $params["nickmeta"] = array(
        'avatar'=> '<img src=' . $avatar_img .'>',
        'profile'=> $u_profile,
        //'profile'=>'<a href="memberlist.php?mode=viewprofile&u=2">test</a>',
        ); // additional values
   
   
    $db->sql_freeresult($result);
    }
require_once dirname(__FILE__)."/src/phpfreechat.class.php";
$params = array();
$params["title"] = "Welcome to The Station Built by the Bands for the Fans!";
$params["theme"] = "default";
$params["frozen_nick"]    = false;
$params["max_msg"] = 20;
$params["max_nick_len"] = 20;
$params["nick"] = $user->data ['username'];
$params["channels"] = array('Group Gathering');

if ($user->data['group_id'] == 5)
{ $params["isadmin"] = true; }

if ($user->data['group_id'] == 8)
{ $params["isadmin"] = true; }

$params["serverid"] = md5('IRRChat');
$params["skip_proxies"] = array('censor','noflood');
$params["shownotice"] = 4;
$params["debug"] = false;
//$params['nickmeta']['avatar']  = sprintf('<img src="%s" alt="" />',$u_profile);
$params['nickmeta']['avatar']  = sprintf('<img src="%s" alt="" />',$_SESSION['user_avatar'].$avatar_img);
$chat = new phpFreeChat( $params );


?>
Station Built by the Bands,, For the Fans!!
DreadPirateVane
Member
 
Posts: 47
Joined: Tue Dec 23, 2008 10:44 pm
Location: Kansas City, Mo.
  • Website
  • YIM
Top

Postby jimmo » Wed Aug 18, 2010 8:55 pm

because of this it fails to open the chat index, is this some sort of cookie session that is being used and not allowing it to connect? any advise would be great, here is my index page code

The sid is added by phpBB's ucp.php after a successful login and shouldn't cause a problem - I get the same appended sid after integrating via phpbb myself without any problems.

Is that your complete index.php page? Where's the $chat->printChat() statement? You won't see anything without that :)
jimmo
Member
 
Posts: 23
Joined: Wed Aug 18, 2010 3:51 pm
Top

Postby DreadPirateVane » Thu Aug 19, 2010 12:01 am

no that is just my parameters and phpbb stuff,, i do get the chat to print up just fine,, it is just the redirect after login that i have the problem,, if the just click the chat lin all is fine,, but i would rather it redirect directly to the chat, hence my problem with that sid,, and it changes each time so,, u got me....
Station Built by the Bands,, For the Fans!!
DreadPirateVane
Member
 
Posts: 47
Joined: Tue Dec 23, 2008 10:44 pm
Location: Kansas City, Mo.
  • Website
  • YIM
Top

Postby SSamiK » Thu Dec 09, 2010 12:35 am

Anyone had any luck with this integration lately?
I've tried a bit, with a clean install of PFC 1.3 running on PHP 5.3.3. I have a chat, now I want to connect it with phpBB 3.0.8. but when I try to visit the chat after doing the changes suggested by Larry I'm unable to access it. Tried a lot of different things, like changing root folder from "../forum/" to full path "/var/www/forum/" and many many more.

Before posting more info, I just want to know; Is this still the best way of doing things? The method in the FAQ did not seem to work at all, that's why I'm trying this one.

Hopefully someone will write a updated enty in FAQ soon.
SSamiK
Member
 
Posts: 14
Joined: Thu Dec 09, 2010 12:24 am
Top

Postby radionow » Thu Dec 09, 2010 2:54 am

I have had luck with it. I didn't really use the tutorial since it didn't work too well. I have a few bugs to fix but I have got it to redirect to login url if not logged in, automatically make you a chat admin if you have the admin or mod permissions, and nickname integration of course.
My Site: http://chickentalk.org/
radionow
Member
 
Posts: 57
Joined: Sun Jan 10, 2010 6:26 pm
Top

Postby OldWolf » Thu Dec 09, 2010 7:43 am

Try this one, I think this was the one I got working for my site:
http://www.phpfreechat.net/forum/viewtopic.php?id=2266
Signature:
Read before Posting: Forum Rules
Note: I am unable to offer support through PM/e-mail at this time.
OldWolf
Site Admin
 
Posts: 1918
Joined: Sun Sep 23, 2007 5:48 am
Top

Postby SSamiK » Fri Dec 10, 2010 12:43 am

Thank you!
Your help is much obliged.
SSamiK
Member
 
Posts: 14
Joined: Thu Dec 09, 2010 12:24 am
Top

Postby OldWolf » Fri Dec 10, 2010 7:01 am

Did that work? I'd like to sticky it so I don't lose it again. :)
Signature:
Read before Posting: Forum Rules
Note: I am unable to offer support through PM/e-mail at this time.
OldWolf
Site Admin
 
Posts: 1918
Joined: Sun Sep 23, 2007 5:48 am
Top

Postby SSamiK » Sat Dec 11, 2010 1:22 am

So far I've gotten the login and redirect to work, but something is making the chat not load. It stays at "Chat loading ...
Please wait" forever. I saw someone in the other tread had a simlar problem but no solution. I'm trying to work it out now.
SSamiK
Member
 
Posts: 14
Joined: Thu Dec 09, 2010 12:24 am
Top

Postby SSamiK » Sat Dec 11, 2010 1:33 am

Got it working. A little typo and/or forgot to rehash. Thanks again.
SSamiK
Member
 
Posts: 14
Joined: Thu Dec 09, 2010 12:24 am
Top

Previous

Post a reply
28 posts • Page 2 of 2 • 1, 2

Return to phpBB, Simple Machines Forum (SMF), and Forum Software (v1.x)

Who is online

Users browsing this forum: No registered users and 4 guests

  • Board index
  • The team • Delete all board cookies • All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
Sign in
Wrong credentials
Sign up I forgot my password
.
jeu-gratuit.net | more partners
Fork me on GitHub