crumble
crumble copied to clipboard
Making the last crumb not be a link
Hi Matt,
Great work. Functions perfectly.
How do I make the last crumb in the breadcrumbs trails -- the crumb that represents the current page -- not be a link?
+1 !
Hi Nickel. Sounds promising. Will you humour a newbie with a syntax example?
There's no support for anything like that. Patches are most welcome.
Okie, just pushed a change for this, have a lookie and let me know if that works for you.
Great! Works fine. Thx! :-)
Cheers Matt.
I did the following in my app root:
script/plugin install git://github.com/mattmatt/crumble.git --force
Then I updated initializers/breadcrumbs.rb like this:
Breadcrumb.configure do
crumb :root, "Drominay", :root_url
[snip]
trail :home, :index, [:home]
[snip]
delimit_with " → "
dont_link_last_crumb
end
The last crumb is still linking to the current page. Sorry if I'm missing something obvious. Any thoughts?
Did you restart the app afterwards? I just tested it, also with just one crumb in the trail, and it works fine.
I just reworked the code a little bit, it was a bit flawed. Could you try it with the current master? Thanks!