I have a view with 2 arguments. The second argument is optionnal.
So it means than I need 2 different breadcrumbs for this view. Is there a way to accomplish this ?

Look at this example, breadcrumbs are the same.

Home » Painting » Dan Groover » Pop-art

http://imart.hsh.co.il/style/2
http://imart.hsh.co.il/style/2/4

on style/2:
It should be Home » Painting » Pop-art

Comments

MGN’s picture

you can make a second breadcrumb for the same view for the case when the second argument is present. Include a php snippet in the Breadcrumb visibility form field (for each breadcrumb) to determine which one should be shown. For example, for the breadcrumb with two arguments:

return is_numeric(arg(2));

This will return TRUE if the second argument is present and a number (or numeric string), allowing the breadcrumb to be displayed. For the breadcrumb with only one argument, use

return !is_numeric(arg(2));

So it will not be displayed if there is a second argument.

MGN’s picture

Status: Active » Fixed

Marking as fixed since the question has been answered.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.