The manual way to do this is to put your menu in a block...then on the block configuration page, only set it to show up on the pages you want. However, if there's a lot of different menu blocks this would get tiresome.
There's a module that will give you contextual menus (ie blocks), the problem is, it uses taxonomy to do the context and I'm not sure if you want that...it's here: http://drupal.org/project/taxonomy_context
MF? Any suggestions?
-Rob Feature
Geeks and God Co-Host
www.bobchristenson.com
Is this just a certain block or the entire right sidebar that is coming and going? That makes a difference.
If it's just a block there are a few options.
I am sure there are other ways but these are the 3 that jump to my mind. The 3rd is a bit technical.
Matt Farina
Geeks and God Co-Host
www.mattfarina.com
Well, each right menu would be different and depends on the page that is displaying it. So, I'd have to create a new block for each possible right menu, and then specify that it only shows on one or two pages.
I found an idea on the drupal site using CCK. Essentially, it involves creating a new content type, and a new template file for that content type.
Here is the link to that info: http://drupal.org/node/62468
I'm not sure how that'll work out for me, but I figured it'd be worth a shot. I think I'll have to hard code the menu and links, so I lose out on drupal's menus.
I also saw a suggestion on using the contemplate module. Anyone use that ?
Syl
Contemplate won't help you here (I don't think...). Basically that module is solely concerned with styling your content, it doesn't have anything to do with controlling the content itself. It just helps you lay things out to look pretty.
-Rob Feature
Geeks and God Co-Host
www.bobchristenson.com
This sounds like a custom solution but it may not be that hard.
Are these blocks going to have the same type of content? Is the content based on or taken from the node? Is it's visibility based on something in the node? What is the visibility based on?
Matt Farina
Geeks and God Co-Host
www.mattfarina.com
So, here's what I did. It seems to be ok for the time being.
I installed the contemplate module.
I created a content type with two fields. One for the center, and one for the right menu (named rightmenu).
Using contemplate - I altered the template and added id types to the fields. I then used those id types in my stylesheet to set up my right side.
It's not perfect, and the menu will have to be hard coded (I might trying to use a block instead and call it - not sure if that is possible yet), but it gives me a right menu that I can enter at the time the page is being created.
Thoughts ?
Basically, what you're doing here is taking the long road to built in drupal navigation blocks. I guess I can't see how this deals with menus only on certain pages. Sure, you could do a menu like this, but if you just put your navigation in a block, you'll have enough styling info to lay it out in CSS rather than using contemplate.
Maybe I'm not sure what you're trying to do, but it seems like you're making this much harder than it is.
-Rob Feature
Geeks and God Co-Host
www.bobchristenson.com
You're theming this so that you have different areas to the content region and not using the block system. This will work as long as you don't want other blocks in that same area (region) as the part of the content you want to look like a block.
If you want other blocks to be in the sidebar region or you want to be able to move that block around and do other block things to it this would be a fairly simple thing to write in php for drupal.
Yet, I am still not sure what it is you are trying to get as you end result. Is it a block of content tied to that page? Is it a menu tied to that page? If it's a menu then there are better ways using the menu system.
Matt Farina
Geeks and God Co-Host
www.mattfarina.com
Maybe an example will help.
Say, I've got five pages on my site.
My left menu says :
Page A
Page B
Page C
Page D
Page E
On Page B, I also have the following extra links on the right:
Link A
Link B
Link C
Link D
Link E
Now, these links may point to pages within my drupal site, or external sites.
Page C, has a completely different set of links on the right.
Link F
Link G
Link H
Link I
Link J
Pages A, D and E do not have any links on the right at all. And, so on throughout the site.
Maybe I am over complicating this.....I wanted to make the right menu something that a user could enter themselves, without having to understand drupal.
Syl
PS: I'm also still quite new to drupal, so I'm not sure of all the ins and outs of it.
To me, this is perfect application of the drupal menu system. I would create new menus for each subpage. Then, those menus become blocks.
In the block configuration, I would manually set blocks to only display on the pages you want.
The problem I see is having a "user" create these items. I'm not sure if you just mean someone with a registered username, or if you're talking about someone who's job it is to administer the site. If it's the latter, you're all set: drupal menus are easy for a novice administrator to create. However, if it's just some regular site user, then you have an issue, because you're not going to want to give them access this deep into your drupal install (not matter how you do it).
I suppose, if you really wanted a user to be able to create these menu items, you could set them up as taxonomy terms...then the user could free-tag terms that end up on that list...but I think that's a whole other discussion...
-Rob Feature
Geeks and God Co-Host
www.bobchristenson.com
So, what I think your saying is that you want user submitted pages to have a block with a list of links for that page. That list of links is tied to just that one page and none others.
hrm.... I'll have to think about this. I don't see it as hard to do but there are a number of ways and I am just thinking about what the best way would be.
If the users that you mean are admins or webmasters than i agree with Rob that the menu system is the way to go.
Matt Farina
Geeks and God Co-Host
www.mattfarina.com
Hey guys,
I'm wondering. I've got some pages on the site that I am developing that have a right menu, and others that do not. The content of the right menu is dependent on the page that is being viewed. What would be the best way to do this ?
So far, I've used divs to specify a right menu in the body of my page. Is there a simpler way ?
Syl