A few questions [message #34329] |
Fri, 20 October 2006 21:13 |
Dan_
Messages: 14 Registered: October 2006
Karma: 0
|
Junior Member |
|
|
Hi,
I just got FudForum and it looks really good. I just got a few questions about it.
1)Can I allow users to have custom rank names after a certain amount of posts, and if so how?
2)In which .tmpl file is the legend at the bottom in?
3)This one i can't remember at the moment lol, but it will come to me.
4) Which is the .php file (and where) that sets the cookie when a user logs in and deletes it when they log out?
Thanks! Dan_
[Updated on: Sat, 21 October 2006 14:10] Report message to a moderator
|
|
|
Re: A few questions [message #34334 is a reply to message #34329] |
Sat, 21 October 2006 06:52 |
Dan_
Messages: 14 Registered: October 2006
Karma: 0
|
Junior Member |
|
|
Oh yeah, I remember 3) now lol:
3) How can i make it so any posts in a certain forum don't count towards overall post count?
Thanks!
|
|
|
Re: A few questions [message #34353 is a reply to message #34329] |
Sun, 22 October 2006 21:56 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
1) You can assign custom "ranks" to users via the user manager admin control panel
2) index.tmpl
3) You cannot without editing the forum's source code.
4) User authentication is handled by login.php.t
FUDforum Core Developer
|
|
|
|
Re: A few questions [message #34376 is a reply to message #34329] |
Tue, 24 October 2006 16:06 |
Dan_
Messages: 14 Registered: October 2006
Karma: 0
|
Junior Member |
|
|
Hi,
I have a couple of things related to my previous questions.
I found login.php (the one in theme/default) and located this:
if ($use_cookies) {
setcookie($GLOBALS['COOKIE_NAME'], $s[0], __request_timestamp__+$GLOBALS['COOKIE_TIMEOUT'], $GLOBALS['COOKIE_PATH'], $GLOBALS['COOKIE_DOMAIN']);
I presume this is the part that sets the cookie to say if a user is logged in? Because I added another setcookie() but when I log in, my one isn't set. Oh and I also made the file readonly, because otherwise it seems to get overwritten.
Also, I see about the custom rank titles thing (as in the one in your name? Core Developer, Administrator etc..) is there a way I can let the user pick their own one if they have over a certain number of posts?
Thanks,
Dan_
|
|
|
Re: A few questions [message #34381 is a reply to message #34376] |
Wed, 25 October 2006 14:09 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
This cookie sets the user's session id. This id will then be used by the forum to identify the user.
The forum will try to re-use the existing cookie if possible simply identifying internally that the session found within the cookie belongs to a certain user.
No, the addition of custom ranks can only be performed by Admins and user-moderators.
FUDforum Core Developer
|
|
|
Re: A few questions [message #34383 is a reply to message #34329] |
Wed, 25 October 2006 14:19 |
Dan_
Messages: 14 Registered: October 2006
Karma: 0
|
Junior Member |
|
|
Ok, thanks again for the replies. I will add the user ranks thing to the suggestions.
I'd like to set my own cookie when the user logs in and remove it when they log out, where would i add this setcookie() in the code?
Thanks,
Dan_
|
|
|
Re: A few questions [message #34386 is a reply to message #34383] |
Wed, 25 October 2006 14:26 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
login.php.t, this script is responsible for both login & logout functions.
FUDforum Core Developer
|
|
|
|
Re: A few questions [message #34397 is a reply to message #34388] |
Thu, 26 October 2006 14:04 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
login.php.t is the actual source file that can be found inside the src/ directory. The login.php is the compiled file.
FUDforum Core Developer
|
|
|
|
Re: A few questions [message #34421 is a reply to message #34417] |
Fri, 27 October 2006 17:51 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
set cookie is done by the user_login() function inside users_reg.inc.t
FUDforum Core Developer
|
|
|
Re: A few questions [message #34438 is a reply to message #34329] |
Sun, 29 October 2006 19:29 |
Dan_
Messages: 14 Registered: October 2006
Karma: 0
|
Junior Member |
|
|
Ok cheers. I've added an extra setcookie() to the code in the user_login(), but when I login it doesn't set my cookie. Any ideas?
|
|
|
|
Re: A few questions [message #34505 is a reply to message #34438] |
Sun, 05 November 2006 17:40 |
Ilia
Messages: 13241 Registered: January 2002
Karma: 0
|
Senior Member Administrator Core Developer |
|
|
After changing the .t files you need to rebuild the theme for the change to take effect.
FUDforum Core Developer
|
|
|