You are here

README.txt in Custom Breadcrumbs 6

Same filename and directory in other branches
  1. 5 README.txt
  2. 6.2 README.txt
  3. 7.2 README.txt
  4. 7 README.txt
/* $Id $ */

Summary
-------
As the name suggests, Custom Breadcrumbs allows you to create and modify your
own breadcrumbs based on node type. After enabling the module, click on
Administer > Site building > Custom breadcrumbs. On this page you'll see
the option to add a new custom breadcrumb. 

Clicking on that link, you have the option to select the node type the breadcrumb 
will apply to. There are two text fields below-- "Titles" and "Paths." When creating 
a breadcrumb, you're simply creating a link. In the custom breadcrumbs interface 
"Titles" describes the text of the breadcrumb while "Paths" describes the Drupal 
path the breadcrumb links to. Each Title must have a corresponding Path. 

To give a very simple example of how to use this module, let's say I have a blog on 
my web site called "Deep Thoughts." To create this, I use the Views module to create 
a page at /blog that displays all the node types "blog post." Whenever a user views 
a blog post I want the breadcrumb to show Home > Deep Thoughts instead of simply Home. 
To do this I would simply type "Deep Thoughts" in the "Titles" field and and "blog" 
in the "Paths" field and save my breadcrumb.

Using the Tokens module, the Custom breadcrumbs module becomes much more flexible 
because breadcrumbs can become dynamic. You can create a breadcrumb like 
Home > Deep Thoughts > [Month of Blog Post] [Year of Blog Post], where "Deep Thoughts" 
links to my main blog page and "[Month of Blog Post] [Year of Blog Post]" links to 
a view that shows only blog posts from the month and year the blog post was created 
(e.g. June 2007). For this, you would do the following:

Node Type:
Blog Post

Titles:
Deep Thoughts
[month] [yyyy]

Paths:
blog
blog/[mm]_[yyyy]

(where of course, blog/[mm]_[yyyy] is the path to the view of blog posts from that month 
and year). So if you created a blog pos on June 13, 2007 your breadcrumb would show 
Home > Deep Thoughts > June 2007 and "June 2007" links to "blog/06_2007" which is a view 
of all blog posts from June 2007.

Also, note that Custom Breadcrumbs doesn't actually check to be sure that a particular path 
exists, so you'll have to check yourself to avoid 404 errors.

Only users with 'administer custom breadcrumbs' permission will be allowed to 
create or modify custom breadcrumbs.

Breadcrumb Visibility
---------------------
Users given 'use php in custom breadcrumbs' permission can include php code snippet that 
returns TRUE or FALSE to control whether or not the breadcrumb is displayed. Note that this 
code has access to the $node variable, and can check its type or any other property.

Special Identifiers
-------------------
The following identifiers can be used to achieve a special behavior:
<pathauto> - will clean any path using the current pathauto module settings, if that module is installed.
<none>     - can be used as a path to have a breadcrumb element that is not hyperlinked.

Identifiers should be added to the paths area in the following format: identifier|path.
To be recognized, the idenfier must be enclosed in angular brackets, and proceed any 
part of the path:
 
For example: <pathauto>|[ogname-raw]

Authors
-------
bennybobw, dbabbage, MGN

File

README.txt
View source
  1. /* $Id $ */
  2. Summary
  3. -------
  4. As the name suggests, Custom Breadcrumbs allows you to create and modify your
  5. own breadcrumbs based on node type. After enabling the module, click on
  6. Administer > Site building > Custom breadcrumbs. On this page you'll see
  7. the option to add a new custom breadcrumb.
  8. Clicking on that link, you have the option to select the node type the breadcrumb
  9. will apply to. There are two text fields below-- "Titles" and "Paths." When creating
  10. a breadcrumb, you're simply creating a link. In the custom breadcrumbs interface
  11. "Titles" describes the text of the breadcrumb while "Paths" describes the Drupal
  12. path the breadcrumb links to. Each Title must have a corresponding Path.
  13. To give a very simple example of how to use this module, let's say I have a blog on
  14. my web site called "Deep Thoughts." To create this, I use the Views module to create
  15. a page at /blog that displays all the node types "blog post." Whenever a user views
  16. a blog post I want the breadcrumb to show Home > Deep Thoughts instead of simply Home.
  17. To do this I would simply type "Deep Thoughts" in the "Titles" field and and "blog"
  18. in the "Paths" field and save my breadcrumb.
  19. Using the Tokens module, the Custom breadcrumbs module becomes much more flexible
  20. because breadcrumbs can become dynamic. You can create a breadcrumb like
  21. Home > Deep Thoughts > [Month of Blog Post] [Year of Blog Post], where "Deep Thoughts"
  22. links to my main blog page and "[Month of Blog Post] [Year of Blog Post]" links to
  23. a view that shows only blog posts from the month and year the blog post was created
  24. (e.g. June 2007). For this, you would do the following:
  25. Node Type:
  26. Blog Post
  27. Titles:
  28. Deep Thoughts
  29. [month] [yyyy]
  30. Paths:
  31. blog
  32. blog/[mm]_[yyyy]
  33. (where of course, blog/[mm]_[yyyy] is the path to the view of blog posts from that month
  34. and year). So if you created a blog pos on June 13, 2007 your breadcrumb would show
  35. Home > Deep Thoughts > June 2007 and "June 2007" links to "blog/06_2007" which is a view
  36. of all blog posts from June 2007.
  37. Also, note that Custom Breadcrumbs doesn't actually check to be sure that a particular path
  38. exists, so you'll have to check yourself to avoid 404 errors.
  39. Only users with 'administer custom breadcrumbs' permission will be allowed to
  40. create or modify custom breadcrumbs.
  41. Breadcrumb Visibility
  42. ---------------------
  43. Users given 'use php in custom breadcrumbs' permission can include php code snippet that
  44. returns TRUE or FALSE to control whether or not the breadcrumb is displayed. Note that this
  45. code has access to the $node variable, and can check its type or any other property.
  46. Special Identifiers
  47. -------------------
  48. The following identifiers can be used to achieve a special behavior:
  49. - will clean any path using the current pathauto module settings, if that module is installed.
  50. - can be used as a path to have a breadcrumb element that is not hyperlinked.
  51. Identifiers should be added to the paths area in the following format: identifier|path.
  52. To be recognized, the idenfier must be enclosed in angular brackets, and proceed any
  53. part of the path:
  54. For example: |[ogname-raw]
  55. Authors
  56. -------
  57. bennybobw, dbabbage, MGN