Meet The Staff development, needs some help

The 2.0.x discussion forum has been locked; this will remain read-only. The 3.0.x discussion forum has been renamed phpBB Discussion.
Locked
HaLo2FrEeEk
Registered User
Posts: 37
Joined: Tue Aug 15, 2006 6:25 am

Meet The Staff development, needs some help

Post by HaLo2FrEeEk » Thu Jul 31, 2008 10:21 am

Hey all, I haven't posted here in a while, but one of my members recently requested a new feature and I think I can do it. I'm pretty familiar with sessions in general, and very familiar with the phpBB tools and code, it's just this particular question gets me for some reason.

What they want is a Meet The Staff section on the site where staff members (mods and admins) can put little descriptions about themselves and their part in our community. I wanted to go a bit above and beyond, and I always get a little carried away, but I've done bigger projects. What I was thinking originally was have a completely seperate (from the forum) page, and have it so that any staff members can sign in (it will use the information from the forum database), but regular members cannot. The user would have to sign in seperately here and at the forum, since session data would not be sent. Then, the staff members will be able to put in their info and it will be formatted and put in a nice little page with that user's avatar and signature text. That, I can do easily.

What I was thinking while browsing around bored was that I could go beyond that, and actually connect the meet the staff control panel and the forum together. What I had in mind is a link that shows up in the navigation bar in the forum for staff members only (I know how to do that), and the staff member can click the link, and it will use his or her session information from the forum to make sure that the person is who they say they are (that way any regular member can't just get that url the old fassion way, whatever that is anymore, they'd have to be validated). The thing that's getting me is how to use the sessions. How does phpBB implement sessions? What session data is transmitted? I know obviously user id is, but what else is sent? What would I need to know to be able to have this page be part of the forum?

Another thing I thought of while I was typing this up was adding a new field to the profile editor page for staff members only (I think I can do that), that says "please enter your "Meet The Staff" description here:". The user could then put that in, and it's automatically pulled out by another display page that gets that user's description, avatar, and sig.

Either way I choose, I have a few ideas for how to set it up. If I choose option 1 or 2, I can make template files that I will parse and let the user choose from different layouts for his "About Me" section, and maybe even upload a picture of the person in real life, if they want. If I go with option 3, I couldn't do this. Either way, I will have it set up so that any changes to their description/picture would have to be approved by me, to prevent abuse, I would have the newest edit go to a row in the database for updates, and when I approve it, it would be copied over to the live section.

I think option 3 would be the simplest for my members, as it's unobtrusive, and clean. Option 1 would be the simplest for me to implement, but would require my members to do a little more work to update it. Option 2 is in between, since the link is right there, and they don't have to log in twice, and they could choose templates.

Since I'll probably go with 2 or 3, for which I will need the session variables, can you guys help me out? What session variables will I need to make sure the person stays logged in over the new pages?

Thank you in advance, I know that if I can get phpBB help from anywhere, this is the best place.

User avatar
ric323
Former Team Member
Posts: 22908
Joined: Tue Feb 06, 2007 12:33 am
Location: Melbourne, Australia
Name: Ric
Contact:

Re: Meet The Staff development, needs some help

Post by ric323 » Thu Jul 31, 2008 10:49 am

Previously I would have moved this post into "MOD Writers Discussion", but that forum is now closed pending the total shutdown of support for phpBB2 at the end of this year.

I'm sorry, but we no longer have support for starting new MODs in phpBB2. Have you considered moving to phpBB3?
The Knowledge Base contains solutions to many common problems!
How to fix "Doesn't have a default value" and "Incorrect string value: xxx for column 'post_text' " errors.
How to do a clean re-install of the latest phpBB3 version.
Problems with permissions? Read phpBB3 Permissions

User avatar
Dog Cow
Registered User
Posts: 2476
Joined: Fri Jan 28, 2005 12:14 am

Re: Meet The Staff development, needs some help

Post by Dog Cow » Thu Jul 31, 2008 4:15 pm

You may also have some luck if you seek out the MOD authors around the site here and try sending one of them a PM.
Moof!
Mac GUI Vault: Retro Apple II & Macintosh computing archive.
Inside Allerton bookLincoln's Tomb at Oak Ridge Cemetery, Springfield

User avatar
ChrisRLG
Former Team Member
Posts: 3420
Joined: Wed Nov 24, 2004 3:18 pm
Location: Essex, UK
Contact:

Re: Meet The Staff development, needs some help

Post by ChrisRLG » Thu Jul 31, 2008 4:37 pm

Dog Cow wrote:You may also have some luck if you seek out the MOD authors around the site here and try sending one of them a PM.
BUT

Only if thier signature advises they will accept them.

If not we would call it recruting/spammin and give you a warning - so check thier signatures FIRST please, as we dont like giving warnings of that nature.
phpBB: The All Important Rules - Bertie Bear 3.0 - No support via PM system - use the forums please.
phpBB v2: Retirement (1/1/2009) : phpBB v3: Read Me Topic - Custom BBCodes - Support Template
Matthew 7:7"Ask and it will be given to you; seek and you will find; knock and a door will be opened to you."
My Links: MS MVP (Consumer Security) - Malware Removal:University - Own Forum: Custom BBCode testing

User avatar
Lumpy Burgertushie
Registered User
Posts: 63196
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Meet The Staff development, needs some help

Post by Lumpy Burgertushie » Fri Aug 01, 2008 4:01 am

basically you would do this like you would any other non phpbb page that you want to create.

make it a phpbb page by putting the sessions code at the top of it and giving it a php extension.

Code: Select all

define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);

//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
//
// End session management
//
or, you could check out this MOD:

http://www.phpbbhacks.com/download/4080
I am available for custom work on a donation basis. Please send me a PM with your needs.
Premium phpBB 3.2 Styles by PlanetStyles.net

New phpbb 3.0 support site

HaLo2FrEeEk
Registered User
Posts: 37
Joined: Tue Aug 15, 2006 6:25 am

Re: Meet The Staff development, needs some help

Post by HaLo2FrEeEk » Fri Aug 01, 2008 5:42 am

Thank you Lumpy, you're the only one who helped me out.

Before I ask another question, I'd like to answer a few.

ric323, I have considered it, but my members are very comfortable with phpBB2 and I don't have the time or energy to try upgrade the database and files. I have many mods installed, many of which I wrote myself, so I would lose those, and I don't want to. Plus, I like phpBB2 better than 3.

Dog Cow & Chris, I don't have the time to seek out mod authors that might or moght not know the answer to my question, I thought it'd be a LOT simpler to ask in a thread, completely following the rules (I tried posting it in the mod writers discussion, but it's closed, as ric said), and get an answer from anyone who knows, instead of pm-ing multiple people repeatedly.

Now, lumpy. Using that, is all required session data sent to this new page, so I could code a MOD using phpBB's session variables and keep that person logged in over the forum and the new meet the staff page?

User avatar
ric323
Former Team Member
Posts: 22908
Joined: Tue Feb 06, 2007 12:33 am
Location: Melbourne, Australia
Name: Ric
Contact:

Re: Meet The Staff development, needs some help

Post by ric323 » Fri Aug 01, 2008 5:48 am

The Knowledge Base contains solutions to many common problems!
How to fix "Doesn't have a default value" and "Incorrect string value: xxx for column 'post_text' " errors.
How to do a clean re-install of the latest phpBB3 version.
Problems with permissions? Read phpBB3 Permissions

Locked

Return to “2.0.x Discussion”

Who is online

Users browsing this forum: No registered users and 5 guests

cron