I seem to successfully have set up Drupal and PHPBB3 so that user registration/login is linked between the two and all user access seems to be fine. However, I am unable to login to PHPBB3 as the admin to be able to configure the forums. I am able to get the phpbb/bypass node to come up in Drupal, but it will not log me in. By looking at the url when clicking submit in phpbb/bypass, I am guessing it is coded to assume you have installed the forum in a folder called "PHPBB3"; however, my install exists in just "PHPBB" without the "3".
Here's what the url's are when I try to use phpbb/bypass:
site/phpbb/bypass - I type my phpbb admin info and click "submit" after which I am directed here:
site/phpbb3/forum/ucp.php?bypass=true&mode=login - I do not have any phpbb3 folder on my site. the forum is at site/forum and ucp.php along with those other files are in site/phpbb
Does anyone know what pypbb/bypass does exactly and where I can go to adjust it to work with the format of my installation?
Thanks.
Comments
You probably missed absolute
You probably missed absolute or relative path in configuration.inc (dont recall which one is used, but I would guess absolute)
Yep... you're a genius
arkepp is, of course, correct. It was my absolute path.
Here are the two lines from configuration.inc, which is located in modules/phpbb:
//Relative path to your phpBB3 directory. Please include a trailing slash ("/").
$phpbbcfg['path_rel'] = 'forum/';
//The absolute path as seen by the webbrowser, including slashes ("/").
//Example: http://www.someplace.com/drupal/forum -> /drupal/forum/
$phpbbcfg['path_abs'] = '/phpbb3/forum/';
Note the unneeded "/phpbb3" for my installation since my forum is located at "site/forum", not "site/phpbb3/forum".
Thanks arkepp!! You rock.
Now other problems...
I changed the configuration.inc file which allowed me to successfully login to phpbb/bypass. However, after logging out the first time after making those changes, I have not been able to login again with any account nor create a new account. Are there other things I need to change that would have been affected by the absolute path change in configuration.inc?
Nope, the absolute path is
Nope, the absolute path is only used for URLs.
Check phpbb/diagnostic, see whether newly created users show up in phpBBs database and make sure you didnt accidentally change any cookie settings in phpBB while you were in the admin controlpanel.
bypass problem
Hi..
I ran into the same problem. Checked the .htaccess to make sure I had everything right as it should.. Still didnt work..
I tried this on your site Arkepp and, it brings me back to drupal.. I know I dont have admin rights on your site but, I should get an error login back and not be thrown back to DRUPAL. I think its the rewritecond that causes it.. I am not an expert in .htaccess language but was wondering about the NOT bypass=true (!=^bypass=true(.*)$).. Is that how it should be?
The only way I got it to work was by disabling .htaccess temporarily.
You mean
You mean http://drupal.i1media.no/phpbb/bypass ? I just tested it, and it works for me with the phpBB superuser account.
If I provide the wrong credentials I get to this page: http://drupal.i1media.no/forum/ucp.php?bypass=true&mode=login , which for me is the regular ACP login. Make sure you are not logged in on my site when you try to do this.
Could it be related to rewritebase or maybe you have a version of Apache different from mine (I use 2.0 and 2.2)?
Lets see...
Ok, that one thing I was wondering about.. The site I am working on with some people is this.. http://dirtyinc.clanservers.com. I stored all the website data in the subdirectory /dirty. So : http://dirtyinc.clanservers.com/dirty. If I try http://dirtyinc.clanservers.com/dirty/forum/bypass, that never works for me. I have to do it this way : http://dirtyinc.clanservers.com/dirty/forum/ucp.php?bypass=true. But if I try and login with that, it brings me back to drupal. And I was not previously logged on of course..
The rewritebase. Its possible that is what I am not understanding. I did set it to /dirty/forum because drupal is in a subdirectory. But still, its not working.. On my test sytem, I am using apache 2.2.6 and on the webhost they are using 1.3.39. The same problem happens on both system..
If you have a clue, it would greatly help me understand this as I am out of solutions for now..
Thanks.
Also, from your site
I also tried your site again but, I am sent back to your mainpage (DRUPAL). I don't get the wrong credentials page like you do (http://drupal.i1media.no/forum/ucp.php?bypass=true&mode=login). Instead I am sent back to this page : http://drupal.i1media.no/user/login?destination=forum/. This is really weird.. I don't understand why you are getting a different result...
Same result, actually
I think we are getting the same result, what I said was that when I put the wrong username/password into phpbb/bypass then I am sent to ucp.php?bypass=true
If I enter the wrong username and password there, like you are doing, I am also sent to Drupal. It only works the first time, because phpBB does not append bypass=true
Two things:
1) Make sure your absolute path in configuration.inc is correct
2) Your rewritebase is probably wrong. I'm not an expert on this either though, never used it. I'd try without the leading slash.
Different approach - making a phpBB user 'owner'
The same problem was a persistent one for me. The only way i would be able to login to phpBB3 om my administrator account was by temporarily renaming the .htaccess file, which worked but was an unwanted situation.
So i made a different user (well, it's the account made in Drupal I use to post with in topics on my forum and on Drupal) 'owner' of the forum (under permissions in the admin panel).
Problem solved, I can now login in to Drupal, go to the forum and there will always be an access link to the administration panel.
(Do not forget to make the desired user in Drupal first. Remember to rename the .htaccess file to something like 123.htaccess before using this solution, and MOST IMPORTANT don't forget to rename it back to .htaccess after you aplied the solution)
-I do realize this is a workaround and not a real solution, but well, i does the job.-
Thats what I had to do as well
Thats what I had to do as well, disabling .htaccess to gain access to phpbb's login, make a user admin and login in using that user from drupal. Its the only way this worked. This :
RewriteCond %{QUERY_STRING} ^mode=login(.)$
RewriteCond %{QUERY_STRING} !^bypass=true(.)$
RewriteRule ^ucp.php(.*)$ ../phpbb/login [L]
never worked for me. All I get is this :
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
This is because ../phpbb/login does not exist for me (where phpbb is the directory where the forum is).
But I knew this would happen because I have no file with login so.. I am missing a configuration step somewhere..
There's two things you can
There's two things you can absolutely not name the directory in which you put the phpBB 3.x's files into. One is "user" , the other is "phpbb"
You can fix it by changing the .htaccess inside phpBB 3.x to also do Drupal's stuff, but the only sane solution is to move it to a different name.
"phpbb3", "forum", "phpBB"... pick your poison, just not anything that overlaps with paths registered by Drupal modules.
Thats what I did...
Yeah, that is what I did. I left it as is since It didnt work for me. Actually, I commented it out. What I really have is this :
RewriteCond %{QUERY_STRING} ^mode=login(.)$
RewriteCond %{QUERY_STRING} !^bypass=true(.)$
RewriteRule ^ucp.php(.*)$ ../forum/login [L]
My base is this http://www.mydomain.com/testsite/drupal/forum
I tried Rewritebase / and Rewritebase /testsite/drupal/forum and the same thing happens in both cases.
Still, the code above doesn't work for me.
Any other thoughts?