Forum Replies Created
-
In reply to: Announcement Board
I posted too soon, my apologies. This looks to be exactly what I am looking for. I just hope I can figure out what “put in a plugin” means…
In reply to: bbPress Session Variable NamesFantastic! That worked perfectly. Thanks so much guys.
In reply to: bbPress Session Variable NamesOK, I take that back. Requiring bb-load.php definitely fixed all the errors, but the functions still aren’t working. They don’t throw an error, but they don’t return anything either and so are pretty much worthless.
Is it perhaps because the files I am trying to use them in are in the parent directory above the bbPress installation?
There must be some way to get access to the bbPress login info directly through PHP…
In reply to: bbPress Session Variable NamesThank you rmccue! bb-load.php was the only file required to make those functions work. I guess that was the source of the chain of includes. Thanks a bunch
In reply to: bbPress Session Variable NamesBy the way, assuming I can get these functions to run, what would be the function for getting the current users’s id?
I got lost somewhere in bb_get_current_user() and bb_get_user() without really being able to figure out what returns what. If I can get them running though, then I can test them, so I should be able to figure it out…
In reply to: bbPress Session Variable NamesIt sounds like just including the bbPress function files and using those functions would be the easiest. I couldn’t figure out which files needed to be included for the login functions to work though.
I tried doing
if (bb_is_user_logged_in())
, which required /bb-includes/pluggable.php and /bb-includes/functions.php, but after I included both those files I was left with the following error:Fatal error: Call to a member function get_row() on a non-object in /bb-includes/functions.php on line 1228
Am I missing some other file, or is it just not possible to use this function outside of the actual bbPress build?
In reply to: bbPress Session Variable NamesOh, and by the way, is there a way to return the current user’s username and ID if one is logged in?
In reply to: bbPress Session Variable NamesJust to clarify, my site is at mysite.com. I’ve got bbPress installed at mysite.com/forums. I’d like to be able to enforce login using the bbPress user system at mysite.com/blah.php, but blah.php isn’t part of the bbPress install so the bbPress functions aren’t available to it. How do I go about enforcing login on a non-bbPress page?
In reply to: bbPress Session Variable NamesHmm… I’m just trying to verify login on a page on the same site that is not part of the bbPress install. I’d like to be able to use the bbPress user system for the entire site if that is possible.
If sessions are the way to go, perhaps I could just include a couple of the function files. Which ones would be necessary to include to enable the is_user_logged_in() function?