Drupal is up and running but how do I ...?

How do I make my theme's secondary links show up only for logged-in users?

I'm using a phptemplate theme, and I want only logged in users to see my secondary links. What's the best way to accomplish this?

Combining sticky post and php snippet

After exhausting all other possibilities (unfortunately, I don't have the luxury of waiting for stable 4.7 to use Jaza's category module) I am using a static page linked to a top level menu item as the index page for a hierarchical section that uses taxonomy terms. I then use this snippet on that static page to pull in nodes from all the categories in that vocabulary- in effect, creating a node listing page for that vocabulary (thank you, Sepeck, for this idea of combining a static page and snippets).

My problem:

On the static page, I would like to post a sticky to serve as a kind of introduction for that page. I don't know how to split the sticky portion (HTML) from the snippet (PHP). If I put the text just above the snippet, the whole thing (including the node listing) becomes a sticky.

Any suggestions?

Here is the snippet code:
<?php
/**
* This php snippet displays content of a specified type, with teasers,
* from certain taxonomy term.
* Sorted by date of creation, most recent first.
* Works with nodes of the flexinode type too.
* To change the length of the list, change $listlength.
* To change the taxomony term, change $taxo_id.
* To change the type of content listed, change the $content_type.
* Tested with Drupal 4.6.3
*/
$listlength="5";
$taxo_id = "3,4,5"; /* comma seperated list */
$content_type = 'story';

No Taxonomy terms in forum post???

Is there a way to use taxonomy for organization of the site but to not have the taxonomy term selection list appear in a forum topic post page? If it is required, is there a way to just give a limited number of options? Or possibly just force them to all be "forum posts" or something?

Thanks

Role-Specific Blocks

Is there a way to make it so certain users can see certain blocks, while other users cannot? Also, can you limit the blocks anonymous users can see?

Creating hidden forums?

I was wondering if anyone has experimented with anything like this - I need to create (several thousand) separate forums. I would however like these forums to be hidden from the normal forum browsing interface.

Seperate primary tabs and secondary tabs

I'm trying to seperate the primary tabs and secondary tabs, so I can basically insert them in different areas from each other. (this should be default, like primary and secondary links, IMHO)

So far I have this in a template.php

function tabs($a) {
 switch($a) {
  case 'primary' :
   print '<ul class="tabs primary">';
   print menu_primary_local_tasks();
   print '</ul>';
  break;
  case 'secondary' :
   print '<ul class="tabs secondary">';
   print menu_secondary_local_tasks();
   print '</ul>';
  break;
 }
}

Then wherever I want to insert a tab in page.tpl.php, i use the tabs() function i just defined, such as:

<?php if ($tabs != "") {
  tabs(primary);
  }
?>

So far everything is working, I managed to get the two tabs (primary & secondary) to appear where I want them. But there is a problem.
Whenever, for example, the secondary tab isn't available to that page, <ul class="tabs secondary"></ul> will be inserted into the code. Since there is no secondary menu on this or that page, that UL needs to not appear. Because it does, my styles for that class interfere with the layout.

While trying to figure out where those UL and CLASS definations are coming from, I found the function theme_menu_local_tasks() in menu.inc. As a test, I changed class="secondary" to class="secondaryX". However, in the page that the webserver serves, it still says "secondary".

Pages

Subscribe with RSS Subscribe to RSS - Post installation