This forum is for assistance with theme development.

How do I determine which breadcrumbs get displayed?

I'm running a site using a phptemplate theme based on "box_grey". I have the taxonomy_context module installed. All the content on my site is organised in "books".

I'm confused about how either the module or the theme decides which breadcrumbs to display. I'm very happy with the taxonomy breadcrumbs getting displayed when I am navigating a particular taxonomy, however when I display the full text of an article I have two issues:

Drupal tips

I'm doing a series of simple drupal tips on my site as a sort of cookbook for simple, mostly theme-related solutions to problems I encounter. Most of these tips I glean from forums when I have a problem. I'm already thinking of problems that I don't have solutions to yet. The goal for me is to point out how to do simple, but very useful things to address problems. Have any problems or solutions you think might fall into this category?

Anyone Gotten CVL to Work with the Drupal CVS to Add Contributions... (themes or modules)

CVS on Mac OS X -> CVL: point and click CVS
http://drupal.org/node/20202

Specifically I am on this page:
http://drupal.org/node/2972

Now I'm no dummie using the CLI and making my way around my Mac's backend features. But this is really confusing me. Has anyone gotten CVL wot work with the Drupal CVS? For instance, I've set up a few environment variables, see below.

lincolns revenge, Content Entry very messed up on page...

I am using a theme I am writing from lincolns revenge as a base. This happens in a freash lincolns revenge as well. (You can see the theme in dev http://www.bushsamerica.com)

Anyway, the title and the main bulk of the content entry screen is BELOW the left column...

The Authoring info Options and Comments are where they should be, but the title and the rest are WAY at the bottom starting where the last left block ends.

how can i detect "comment/reply/*" on the node.tpl.php?

im trying to customize the node display for the /comment/reply/nid pages in my theme. is there a way to detect if the user is on comments/reply pages? and display one piece of content if it is and another if any other page?
:)
thanks!

Identifying modules and nodes from the body tag, my proposed solution

I am using smarty but this isn't a smarty only solution.

I've been looking for a couple weeks now for a way to give the body an id based on the module or node I was pulling up. This solution is pretty simple and I may be reinventing the wheel here. Please let me know if there's a better way to do this.

function get_body_id(){
	$q = $_GET['q'];//In my code I actually check post and query string with a function I made, but this will work also

	$body_id = str_replace('/','-', $q);

	return $body_id;
} 

In the body tag I just call the function like so: <body id="{php}echo get_body_id();{/php}" {if $node}class="node"{/if}>. Now for you non smarty users you'd use: <?php= get_body_id(); ?>. Notice that I also put a conditional statement that will identify the page as displaying a node, which helps me identify node pages from everything else.

This solution will just print out the module id for the body id or "node-1" (for example) if the page is a node. It works pretty well for most of the things I am doing but I don't know how well it would work for complicated page calls.

The beauty of id tags is that I can just ignore the tags for arbitrary pages.

Is there something out there better than this? Does drupal have something built-in? I've been looking around for a while but I haven't found anything. If there isn't they need to include that in a future release because body id's, classes are the only way to get ultimate flexibility in theming (I know bc my designer has been yelling at me ab this for days).

Pages

Subscribe with RSS Subscribe to RSS - Theme development