Custom Breadcrumb by content node type AND taxonomy term
One thing that I needed to do was customize the breadcrumb based upon the taxonomy term that was associated with it. For example, given that you have a CCK content type named "Profile" and you used a taxonomy to classify the type of profile, such as a Faculty member, a student, Alumni, etc... Because each instance of the Profile would be either a Faculty Member, etc., We wanted to customize the breadcrumbs on that node page.
Custom Breadcrumbs allows you to specify a snippet of PHP code that you can use to evaluate the node and test if your taxonomy node belongs to the node. Your snipped can return true, in which case, your custom breadcrumbs will be activated. By creating custom breadcrumbs with different conditions, I was able to have customized breadcrumbs for the Faculty vs. a student.
Here's the PHP, the number you see here is the TERM ID of the "Faculty"
/* is the node have a type that is administrator */
return (isset($node->taxonomy[65]));
Lastly, here's a couple of screen shots:



Comments
Post new comment