PDA

View Full Version : Little help please, w/ custom user group and author info


JJR512
22 Mar 2001, 03:49
What I want is for some of my members, those who are on my SETI@home team, to have a link to my SETI@home page somewhere in their post. I think it would be cool/neat to have it in the author info area (the left column), right above their registration date.

I tried this with a custom user profile field, and I edited the appropriate template so it shows up in the right spot. But they can edit the contents of the field. This I do not want, because I only want one thing displayed, and only for the certain members. Non-team-members were putting silly stuff in the field, etc.

So now I'm thinking I can make a custom user group (i.e., like Registered or Moderator), called SETI Group Members. I can manually add people to this group. I'm thinking there must be some kind of way the board, when displaying posts, can check to see if the member is a member of that group, and if so, to put this link above the registration date.

I've already made the group; now I just need to know how to make the checking part, and include the link in that spot. Any help, please? :)

22 Mar 2001, 04:09
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------



That should give you an idea of what to put in showthread.php

22 Mar 2001, 05:02
I just thought of something. I'm on the SETI team, as are moderators and regular members. Obviously, we all can't be part of the same user group. If I add multiple user groups, like SETI_Admin, SETI_Mod, SETI_SuperMod, and SETI_Member, how would the above little code be made to check all those groups?

And assuming I correctly set permissions for each group, would putting a Moderator in another group have any effect on his/her abilities?

22 Mar 2001, 05:06
Or is there maybe a better way to do this? I could make a new field in the user table, and if I manually set the value to 1 for someone, the link would show up. This is probably the best way.

But I don't know how to write the part...the same part, that checks the value to see if it's 1 or not.

22 Mar 2001, 16:31
Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------


You must add a field named "seti" to the User table, and set each seti member to "1" by hand. Add $setilink where you want it to appear under each user's info or in the icon line.

22 Mar 2001, 19:39
OK, thanks! Two questions:

1. Does it matter where in showthread.php I put this code?

2. What is the syntax of a query I could issue to the db through phpMyAdmin to change the value for a member?

22 Mar 2001, 19:42
1. Find


Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------


and put it right after that.
2.

Code:
---------------
Code is only visible to licensed users, and only when logged into the forums.
---------------

and substitute the user's ID for XX.

HTH.