Topic: Getting the forum ID
I'd like to get the forum id, and post id of the topic. Is there a way through set variables to determine this?
If not, I can use mysql to figure it out, but I'd just like to know if there is an easier way
You are not logged in. Please login or register.
PunBB Forums → PunBB 1.2 discussion → Getting the forum ID
I'd like to get the forum id, and post id of the topic. Is there a way through set variables to determine this?
If not, I can use mysql to figure it out, but I'd just like to know if there is an easier way
Where would you like to use this?
Well, I wanted to allow html for a certain forum for certain members. So I'll simply check what forum it is, what member group they are, and then choose to parse everything, or allow html in it.
Actually, I checked the parser.php, and was confused where the html was parsed in the message parse function. If I find it, I could make a new function to parse everything but the html. Could anyone tell me what I would need to take out?
Edit: Actually, I just replaced the "\n" with a line break, so that should be good enough.
You'd need to put a check around the pun_htmlspecialchars() function call. I suggest you pass on these variables in viewtopic.php. It should be possible
I've been trying to use the database to determine the forum id, but I am having some trouble. But it must get the variable when viewing the page cause otherwise, it would not know the name of the forum for the navigation.
EDIT: Okay, I got the forum id working, but now i'm having trouble getting the poster's id. I tried using the variables such as $cur_post['poster_id'] but it didn't work...
$fid for forum ID, $cur_post['uid'] for user ID and $cur_post['g_id'] for group ID.
Thanks! It worked beautifully
PunBB Forums → PunBB 1.2 discussion → Getting the forum ID
Powered by PunBB, supported by Informer Technologies, Inc.