MyBB Community Forums

Full Version: Portal In Different Directory
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hey, having a little trouble

my forum is set to /forum/

how do i make the portal page work at /

I have looked around, but its late here and i have given up! i have it working but it seems to not actually log in!
You can't really, because logging in wouldn't work and it might not be able to load that stats and announcements etc.

The reason it wouldn't login is because your cookie path will be /forum/ so it works on the forum but that won't work if the portal isn't in /forum/.
You can set your cookie path to the whole domain can't you? I remember doing this with MyBB 1.2.x. I had renamed portal.php to index.php and placed it in my root directory while my forum was in my /forum/ directory. Unless something has changed all you need to do is set the cookie domain to .mydomain.com and make some edits to the portal.php file (I forget which off hand since I don't have access to a working MyBB site right now).
It'll still need a path; with the forums themselves being in /forum/, the cookie path would need to be /forum/, but if portal.php wasn't in /forum/, the cookie path would need to just be / to get logins to work, and I don't think there's a way to have 2 cookie paths.
Hmm, i've just set up a redirect for now, if anyone has any more ideas please post them here or contact me via PM, cheers.
Just an idea, why not create a blank index.php file, and put...

<?php
     include('forum/portal.php');
?>

It could work. It might throw some errors back though, but I have one last idea if that happens. Post the results back in this thread if you try it...