http://api.drupal.org/api/function/hook_view/6
menu_set_location
The above mentioned function should be changed.
menu_set_location is not supporting in Drupal 6.
Regards.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | 668650_nospace.patch | 1010 bytes | jhodgdon |
| #3 | 668650.patch | 1011 bytes | jhodgdon |
| #2 | 668650.patch | 1011 bytes | jhodgdon |
Comments
Comment #1
jhodgdonGood point! The example for hook_view() in both D6 and D7 uses the menu_set_location() function, which does not exist.
http://api.drupal.org/api/function/hook_view/7
Should be fixed in D7, then ported back to D6.
Comment #2
jhodgdonLooking at the doc for the old menu_set_location() function in Drupal 5, as well as the current example for hook_view() (which is also left over from Drupal 5, sheesh!), it looks like the main purpose is to set the breadcrumb trail. So in D6/D7, I think it should be using drupal_set_breadcrumb().
Which means the array is a bit different as input to drupal_set_breadcrumb() as opposed to menu_set_location(). Also, http://api.drupal.org/api/function/drupal_set_breadcrumb/7 wants the array to start with Home and not to include the current page.
So I've rewritten the sample function body... needs a review, then can be ported to Drupal 6.
Comment #3
jhodgdonActually, try this one (small capitalization change).
Comment #4
dries commentedWe can remove the space before ')'. Otherwise the patch looks good to me.
Comment #5
jhodgdonSorry about that. Habits left over from previous coding standards in different project...
Comment #6
dries commentedCommitted to CVS HEAD. Thanks! Rock on, jhodgdon.