I run a school's website and each teacher has their own page, I want to add the ability to let the teachers add add and edit their own pages and automatically add these to a sub menu that shows when you go to their page. So for example if there is a teacher Bob, then when you go to schoolsite.com/staff/bob, there should be Bob's main page and a menu block with subpages he's created like schoolsite.com/staff/bob/history. I am having trouble with figuring out how to do this, with taxonomy, cck, views, or what? The pages automatically being added only to their submenu and links being created is the important part.

Comments

2houseplague’s picture

Well, there are a number of things going on here, so best to consider them separately. You say that each teacher will have his own "page" but you don't mention whether this part of the site already exists, how many teachers there will be ultimately and what amount (if any) of administrative responsibility over content you're prepared to give teachers. This matters since the creation of content and the creation of menus are separately permissioned on Drupal. In other words, teachers might be able to make posts, but somebody else (like the site admin) would have to create these menus. Let's assume you don't yet have the "teacher's page" schemed out yet, there are a couple of ways to make such a page. You could use their user profile page, and (with minor template modification) provide a list of their posts right on the profile page. That's not exactly what you described, but it would give each teacher a page, and provide on each page a "menu" of that teacher's posts. Another approach (a little more complicated) would be to make a Views page for each teacher. This would allow you to list and sort their posts according to filters and other logical rules, like alphabetically or reverse chronological order. You didn't mention how you wanted the teacher's page to look, so I'm just offering ideas here. In either scenario, the "menu" effect could be achieved using a Views block that would list posts (just like a Views page). Then you would set the block's visibility to just that teacher's page. This might not be practical if you have dozens of teachers, for example. All these solutions have the benefit of requiring no manual "menu making". Another aspect, which I glean from your description of the URL (schoolsite.com/staff/bob/history) is how you want to construct the URLs for teacher-submitted content, and what hierarchies you want to suggest with them. Remember that URL construction rules in Drupal are independent of other hierarchies that may exist among the content. For example, if what you want is for the URLs of all of teacher Bob's posts to follow the scheme site/com/staff/bob/[title] or site/com/staff/bob/[category]/[title], you can set that up using the Pathauto module. I've thrown a lot of darts on the wall, but I guess I need to know more before guiding you towards the best solution. Hope I helped.

Proton Cannon

philipw’s picture

So I thought about the views method, but I do have over a dozen teachers and someone else will be taking over this site eventually and I want this automated so that when there is a new teacher all that has to be added is a new user and maybe a page for them. I understand the part about pathauto, I already use it and got what you mean.

asdfghjklñ’s picture

I'm considering Drupal for a school, and I'm interested in the problem you've raised. However, the turnover for our school is large and a lot of the primary teachers swap their yeargroups over every couple of years. So with my current site (e107) I created it so that each teacher automatically had a blog with comments by pupils, but I opted to categorise all other content by 'yeargroup' for primary and by 'subject' (for secondary).

For Drupal, I am hoping that teachers will still have their blog, but then no rigid categorisation will be needed: teachers will create forum-topics, groups and wikis based on the curriculum sections or topics, and then invite the relevant classes/pupils to join. And after the topic has finished, hopefully they could collate all the good material together into one topical book, before starting again on another topic.

I'm hoping it will be a more 'organic', community-orientated structure.
Have you seen the 'Drupal Ed' release? What do you think of it?